/*
 Theme Name: Divi 5 Child
 Theme URI: 
 Description: Child theme for Divi 5
 Author: Jason Atri
 Template: Divi
 Version: 1.0.0
*/

/* ===== Design audit 2026-10-06, owner's calls of 2026-10-07 ===== */

/* I-15: one keyboard focus ring everywhere: navy on light, white on the dark bands.
   !important because Divi and the plugins set outline:none or near-invisible rings. */
:focus-visible{outline:2px solid #0f1b2d!important;outline-offset:2px}
.et-l--footer :focus-visible,
.rme-home .dk :focus-visible,.rme-home .hero :focus-visible,.rme-home .lux :focus-visible,.rme-home .tile:focus-visible{outline-color:#fff!important}
/* I-15: the skip link (functions.php) shows only when it has keyboard focus */
.rme-skip-link{position:absolute;left:-9999px;top:8px;z-index:100000;padding:12px 18px;background:#0f1b2d;color:#fff!important;font:600 13px/1 'Montserrat',sans-serif;letter-spacing:1px;text-transform:uppercase;text-decoration:none}
.rme-skip-link:focus{left:8px}

/* I-5: /properties/ keeps its <h1> for search engines and screen readers without showing
   it. Divi's Customizer CSS hid it with display:none, which hides it from both. */
#left-area #post-12 h1.entry-title.main_title{display:block;position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap;border:0}

/* I-2: Divi's primary and link colour (#000e35) becomes the footer navy. Divi 5 prints
   these variables in an inline :root block, which html:root outranks; the menu rules are
   the Customizer's own hard-coded copies of the same colour. */
html:root{--gcid-primary-color:#0f1b2d;--gcid-link-color:#0f1b2d}
body #top-header,body #top-header a{color:#0f1b2d} /* not !important: the red "Sign In" keeps its colour */
#top-menu>li>a,.et_mobile_menu li a,.mobile_menu_bar:before{color:#0f1b2d!important}

/* I-10: Divi's contact form joins the site's one field style (white, 1px #cfd4dc,
   square, 46px, Poppins 14px). It was Marcellus on a grey fill at 59px. */
body .et_pb_contact_form_container .et_pb_contact_field .input{font-family:'Poppins',sans-serif!important;font-size:14px!important;font-weight:400!important;color:#222!important;background-color:#fff!important;border:1px solid #cfd4dc!important;border-radius:0!important;padding:0 14px!important;height:46px}
body .et_pb_contact_form_container .et_pb_contact_field textarea.input{padding:12px 14px!important;height:auto;min-height:150px}

/* P-4: 16px text in form fields on touch screens, so iOS stops zooming the page on focus.
   :is(#page-container, body) carries an id's weight, to outrank the plugins' !important
   field sizes; it still matches the modals that sit outside #page-container. */
@media (pointer:coarse){
  :is(#page-container,body) :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=submit]):not([type=button]):not([type=hidden]),select,textarea){font-size:16px!important}
}

/* P-3: 44px tap targets on phones */
@media (max-width:980px){
  .mobile_menu_bar{display:inline-block;min-width:44px;min-height:44px;text-align:right}
  body .et_pb_contact_form_container .et_pb_contact_submit{min-height:44px}
  /* Footer social icons: an invisible 44px hit area round each 32px icon. They sit 46px apart,
     so the areas never overlap; nothing moves. */
  .et-l--footer .et_pb_social_media_follow a.icon::after{content:'';position:absolute;inset:-6px}
}

/* ===== I-6, I-7 (owner, 2026-10-08; mockups/site-design-2026-10/): two page openings ===== */
/* .rme-band is the plain navy band for directory and data pages, and .rme-hero is the photo
   hero. .rme-lbl is the homepage's small spaced label with its red rule. FSO (team, office and
   offices), the IDX area and hub pages, and the blog templates here all use these classes, so
   they live in the one stylesheet that every page loads. */
.rme-lbl{display:inline-block;margin:0;padding:0;font:500 11px/1.4 'Montserrat',sans-serif;letter-spacing:.28em;text-transform:uppercase;color:#b8bcc4}
.rme-lbl:after{content:'';display:block;width:50px;height:1px;margin:10px auto 0;background:#c8102e}
.rme-band{margin:0;padding:56px 24px 60px;box-sizing:border-box;text-align:center;color:#fff;background:#0f1b2d}
.rme-hero{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:400px;margin:0;padding:72px 24px;box-sizing:border-box;text-align:center;color:#fff;background:#0f1b2d center/cover no-repeat}
.rme-hero:before{content:'';position:absolute;inset:0;background:linear-gradient(rgba(15,27,45,.42),rgba(15,27,45,.72))}
.rme-hero>*{position:relative;z-index:1}
.rme-hero .rme-lbl{color:#fff}
.rme-band h1,.rme-hero h1{margin:16px auto 0;padding:0;max-width:900px;font-family:'Montserrat',sans-serif;font-weight:300;line-height:1.12;letter-spacing:.08em;text-transform:uppercase;color:#fff}
.rme-band h1{font-size:clamp(26px,3.4vw,40px)}
.rme-hero h1{font-size:clamp(30px,4.6vw,56px)}
.rme-band-sub{margin:12px auto 0;padding:0;max-width:640px;font:300 15px/1.6 'Poppins',sans-serif;color:#c9cdd4}

/* The Divi content pages' photo hero: 16 pages (/about/, /contact/, /client-services/ and its
   six pages, the guides, featured, luxury, commercial, buyer compensation, home valuation).
   Each keeps its own Divi section, photo and words; these rules lay the existing modules out
   as .rme-hero. The blurb's heading becomes the label above the H1 and its text the line
   under it. The match is a first section with a background whose first row holds a blurb,
   the shape all 16 share. /error/ and the homepage have no blurb there. A browser without
   :has() keeps the Divi look. */
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0){position:relative;display:flex;flex-direction:column;justify-content:center;min-height:400px!important;height:auto!important;padding:72px 24px!important;background-color:#0f1b2d!important;background-blend-mode:normal!important}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0):before{content:'';position:absolute;inset:0;z-index:0;background:linear-gradient(rgba(15,27,45,.42),rgba(15,27,45,.72));pointer-events:none}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0)>.et_pb_row_0{position:relative;z-index:1;display:flex!important;flex-direction:column;align-items:center;width:100%!important;max-width:900px!important;margin:0 auto!important;padding:0!important;text-align:center}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0)>.et_pb_row_0:before{content:none!important} /* the SCROLL DOWN rail */
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0)>.et_pb_row_0>.et_pb_column,
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) :is(.et_pb_blurb_0,.et_pb_blurb_content,.et_pb_blurb_container){display:contents!important}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) .et_pb_main_blurb_image{display:none!important}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) :is(.et_pb_module,.et_pb_text_inner){margin:0!important;padding:0!important;width:auto!important;max-width:100%!important;text-align:center!important}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0)>.et_pb_row_0>.et_pb_column>.et_pb_module:not(.et_pb_blurb){order:2}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) .et_pb_module_header{order:1;max-width:640px;margin:0!important;padding:0!important;text-wrap:balance}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) :is(.et_pb_module_header,.et_pb_module_header *){font:500 11px/1.4 'Montserrat',sans-serif!important;letter-spacing:.28em!important;text-transform:uppercase!important;color:#fff!important}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) .et_pb_module_header:after{content:'';display:block;width:50px;height:1px;margin:10px auto 0;background:#c8102e}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) h1{margin:16px 0 0!important;padding:0!important;font-family:'Montserrat',sans-serif!important;font-size:clamp(30px,4.6vw,56px)!important;font-weight:300!important;line-height:1.12!important;letter-spacing:.08em!important;text-transform:uppercase!important;color:#fff!important;text-align:center!important}
/* /client-services/mortgage-partners/executive-home-lending/ has a second H1 in the hero: it reads as the line under the first */
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0)>.et_pb_row_0>.et_pb_column>.et_pb_module:not(.et_pb_blurb)~.et_pb_module:not(.et_pb_blurb) h1{margin-top:14px!important;font:300 16px/1.6 'Poppins',sans-serif!important;letter-spacing:normal!important;text-transform:none!important}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) .et_pb_blurb_description{order:3;max-width:640px;margin:14px auto 0!important;padding:0!important}
body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) :is(.et_pb_blurb_description,.et_pb_blurb_description *){margin:0;padding:0;font:300 16px/1.6 'Poppins',sans-serif!important;letter-spacing:normal!important;text-transform:none!important;color:rgba(255,255,255,.9)!important}

@media (max-width:760px){
  .rme-band{padding:40px 20px 44px}
  .rme-hero{min-height:300px;padding:56px 20px}
  .rme-band h1,.rme-hero h1{letter-spacing:.05em}
  .rme-lbl{font-size:10px;letter-spacing:.2em}
  .rme-band-sub{font-size:14px}
  body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0){min-height:300px!important;padding:56px 20px!important}
  body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) h1{letter-spacing:.05em!important}
  body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) :is(.et_pb_module_header,.et_pb_module_header *){font-size:10px!important;letter-spacing:.2em!important}
  body.page .et_pb_section_0.et_pb_with_background:has(>.et_pb_row_0 .et_pb_blurb_0) :is(.et_pb_blurb_description,.et_pb_blurb_description *){font-size:14px!important}
}

/* I-7: News and Notes and the category archives (home.php, category.php, rme_news_page()).
   The homepage's News card (rme-home.css, .news), three to a row. */
.rme-news-wrap{max-width:1280px;margin:0 auto;padding:0 40px 88px;box-sizing:border-box;color:#3d3d3d;font:300 14px/1.65 'Poppins',sans-serif}
.rme-news-cats{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin:0;padding:32px 0 0;list-style:none}
.rme-news-cats li{margin:0;padding:0;list-style:none}
.rme-news-cats a{display:block;padding:12px 16px;border:1px solid #d9d4c7;font:600 11px/1 'Montserrat',sans-serif;letter-spacing:.14em;text-transform:uppercase;white-space:nowrap;color:#0f1b2d;text-decoration:none;transition:border-color .3s}
.rme-news-cats a:hover{border-color:#0f1b2d}
.rme-news-cats a[aria-current]{background:#0f1b2d;border-color:#0f1b2d;color:#fff}
.rme-news-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:44px 24px;margin-top:40px}
.rme-news-grid>a{display:block;color:#3d3d3d;text-decoration:none}
.rme-news-grid .ph{aspect-ratio:3/2;overflow:hidden;background:#e9e7e1}
.rme-news-grid .ph img{display:block;width:100%;height:100%;object-fit:cover;transition:transform 1.1s cubic-bezier(.2,.6,.2,1)}
.rme-news-grid>a:hover .ph img{transform:scale(1.07)}
.rme-news-grid .meta{margin-top:16px;font:500 10px/1.4 'Montserrat',sans-serif;letter-spacing:.2em;text-transform:uppercase;color:#6b6b6b}
.rme-news-grid h2{margin:8px 0 0;padding:0;font:500 17px/1.4 'Montserrat',sans-serif;letter-spacing:normal;text-transform:none;color:#0f1b2d;transition:color .3s}
.rme-news-grid>a:hover h2{color:#c8102e}
.rme-news-grid .more{display:inline-block;margin-top:14px;padding-bottom:5px;border-bottom:1px solid #c8102e;font:600 12px/1 'Montserrat',sans-serif;letter-spacing:.18em;text-transform:uppercase;color:#0f1b2d}
.rme-news-pager{display:flex;flex-wrap:wrap;justify-content:center;gap:12px;margin-top:64px}
.rme-news-pager a{display:inline-block;padding:13px 28px;border:1px solid #0f1b2d;font:600 12px/1 'Montserrat',sans-serif;letter-spacing:.18em;text-transform:uppercase;color:#0f1b2d;text-decoration:none;transition:background .3s,color .3s}
.rme-news-pager a:hover{background:#0f1b2d;color:#fff}
.rme-news-none{margin:48px 0 0;text-align:center}
@media (max-width:980px){.rme-news-grid{grid-template-columns:repeat(2,1fr)}}
@media (max-width:760px){
  .rme-news-wrap{padding:0 20px 56px}
  /* the category buttons stay on one line and scroll sideways, rather than stacking three rows deep */
  .rme-news-cats{flex-wrap:nowrap;justify-content:flex-start;overflow-x:auto;margin:0 -20px;padding:24px 20px 4px;scrollbar-width:none}
  .rme-news-grid{grid-template-columns:1fr;gap:40px;margin-top:28px}
}
@media (prefers-reduced-motion:reduce){.rme-news-grid .ph img,.rme-news-grid h2{transition:none}}
