/* 
Theme Name: Hello Elementor Child
Theme URI: https://github.com/elementor/hello-theme-child/
Description: Hello Elementor Child is a child theme of Hello Elementor, created by Elementor team
Author: Elementor Team
Author URI: https://elementor.com/
Template: hello-elementor
Version: 2.0.0
Text Domain: hello-elementor-child
License: GNU General Public License v3 or later.
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Tags: flexible-header, custom-colors, custom-menu, custom-logo, editor-style, featured-images, rtl-language-support, threaded-comments, translation-ready
*/

/* Add your custom styles here */

a {color:#d30023;text-decoration: none;}
.comments-area a, .page-content a {text-decoration: none;}
[type=button], [type=submit], button {color:#fff;background:#d30023;border:2px solid #d30023;text-transform: uppercase;}
[type=button]:hover, [type=submit]:hover, button:hover {color:#fff;background:transparnet !important;}

.page-header {display:none !important;}
.contact-karan-photo {padding: 45px; border-radius: 999px !important; float: right; max-width: 400px !important; }
.eael-tabs-nav ul li:before {display:none;}
.eael-tabs-nav ul li {width:25%;}
.heading-title {position: relative; text-transform: uppercase; padding-bottom: 12px; margin-bottom: 36px;display:block;}
.heading-title:after {content: ''; display: inline-block; position: absolute; bottom: 0; left:0; right:0; max-width: 90px; width: 50%; margin: 0 auto; height: 2px; background: #d30023;}

/*HEADER START*/
.menu-item.current-menu-item a.hfe-menu-item:hover, .menu-item a.hfe-menu-item:focus {background:var( --e-global-color-primary ) !important;color:#fff !important;}
/* .bx-wrapper .bx-controls-direction a {z-index: 90 !important;} */
@media (min-width: 1025px) {.mw-fav-desktop {display: none !important;}}
@media (max-width: 1024px) {.mw-fav-mobile {display: none !important;}}
.bootstrap-realtypress .rps-favorited-heart {z-index:90 !important;}
.site-content {padding-bottom:0;}
.title-box_style_1 {display:none;}
.ehf-header #masthead {box-shadow:0px 0px 10px rgba(0,0,0, 0.2);margin-bottom:20px;}
.stm_mobile_switcher {padding: 10px !important; width: 50px !important; height: 40px !important; opacity: 1 !important; margin: 0 !important; overflow: visible !important;}
.stm_nav_menu .stm_mobile_switcher.active:after {display:block !important;}
.stm_nav_menu.active .stm_mobile_switcher.active {top:-999em;}
.menu-main-menu.div.active {top:-999em;}
.title-box_style_1 .breadcrumbs-wrap .breadcrumbs {display:none;}
/*HEADER END*/



/*FOOTER START*/
.realtor-logo {width: 100%; max-width: 176px !important; margin: 0 20px 15px 0; display: inline-block; float: left;}
.rps-footer {} /*display:none !important;*/
.elementor-message {color:green;text-align:center;}
.crea_text {justify-content: left; padding-left: 0px; padding-right: 0px;margin: 0; line-height: 16px;color:#aaa; font-size: 13px;margin-bottom:20px;}
.crea_text .realtorLogo span {background: url(https://soldbykaran.com/wp-content/uploads/2020/10/realtorLogo.svg) no-repeat; background-size: auto 100%; display: block; width: 35px; min-width: 30px; height: 30px; float: left;}
.crea_text .mlsLogo span{background: url(https://soldbykaran.com/wp-content/uploads/2020/10/mlsLogo.svg) no-repeat; background-size: auto 100%; display: block; width: 75px; min-width: 65px; height: 30px; float: left; margin-top: 2px;}

.grecaptcha-badge {visibility: hidden;}

.subscribe-left {float: left !important;width: 58% !important;}
.subscribe-right {float: right !important;width: 40% !important;background:#d30023;border:2px solid #d30023 !important;color:#fff;text-transform:uppercase;font-weight: bold;}
.subscribe-right:hover {background:transparent;}
/*FOOTER END*/






/*TABLET MOBILE*/
.hfe-creative-menu, .hfe-creative-menu a {z-index: 999999999 !important;}
@media screen and (min-width: 1024px){
.stm_nav_menu .stm_mobile_switcher {display:none !important;}

}
@media (max-width: 1024px){
.stm_nav_menu .stm_mobile_switcher {display:block !important;}

}

@media (max-width: 768px){
.elementor-icon-box-wrapper{text-align:center !important;}

.eael-tabs-nav ul li {width:47%}
	
.elementor-8542 .elementor-element.elementor-element-b254905 .elementor-repeater-item-b69e215 .swiper-slide-bg {background-position:-100px 0;}	
	
.heading-title {text-align:left;}
.heading-title:after {right:0;left:0;}

}

@media (max-width: 425px){
.contact-karan-photo {float:right;}
.elementor-8542 .elementor-element.elementor-element-b254905 .elementor-repeater-item-b69e215 .swiper-slide-bg {background-position:-300px 0;}	

.elementor-icon-box-wrapper{text-align:center;}

.heading-title {text-align:center;}
.heading-title:after {right:0;left:0;}

}


/*HOME PAGE*/
.bx-wrapper .bx-controls-direction a {z-index: 9 !important;}
/* .home-sliders .bx-wrapper .bx-wrapper {margin:0;padding:0;max-width: unset !important;} */
.home-big-button .elementor-widget-container {border-radius: 10px;}
.home-big-button .elementor-icon-box-description a {font-size: 1rem; font-weight: bold; border: 1px solid #fff; padding: 6px 13px 6px 15px; text-decoration: none !important; border-radius: 50px; background-color: #fff; color: #111 !important; text-transform: uppercase;}
.home-big-button .elementor-icon-box-description a:hover {background:transparent;color:#fff !important;}


/*LISTINGS PAGE*/
/* --- DESKTOP BEHAVIOR (768px+) --- */
@media (min-width: 768px) {
    .result-filter-frm .panel {
        display: flex !important;
        flex-direction: column;
        height: calc(100vh - 155px);
        position: sticky;
        top: 155px;
        margin-bottom: 20px;
    }
    .result-filter-frm .panel-body {
        display: block !important;
        overflow-y: auto;
        flex: 1;
        padding: 15px;
    }
    .result-filter-frm .panel-footer {
        display: block !important;
        padding: 15px;
        border-top: 1px solid #eee;
    }
}

/* --- MOBILE BEHAVIOR (767px and below) --- */
@media (max-width: 767px) {
    .result-filter-frm.is-sticky {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        z-index: 9999;
    }

    .result-filter-frm:not(.is-open) .panel-body,
    .result-filter-frm:not(.is-open) .panel-footer {
        height: 0;
        margin: 0;
        padding: 0;
        visibility: hidden;
        overflow: hidden;
        opacity: 0;
    }

    .result-filter-frm:not(.is-open) .panel {
        border: none;
        background: transparent;
        margin-bottom: 10px;
    }

    /* FULL SCREEN OPEN STATE */
    .result-filter-frm.is-open {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100vw !important;
        /* Using dvh (dynamic viewport height) to account for browser bars */
        height: 100dvh !important; 
        z-index: 10000;
        background: #fff;
    }

    .result-filter-frm.is-open .panel {
        height: 100%;
        display: flex;
        flex-direction: column;
        margin: 0;
        border: none;
    }

    .result-filter-frm.is-open .panel-body {
        display: block !important;
        visibility: visible;
        opacity: 1;
        flex: 1;
        overflow-y: auto;
        padding: 20px;
    }

    .result-filter-frm.is-open .panel-footer {
        display: block !important;
        visibility: visible;
        opacity: 1;
        padding: 15px 15px calc(15px + env(safe-area-inset-bottom)); /* Pushes button above mobile browser bar */
        background: #fff;
        border-top: 1px solid #eee;
        min-height: 80px; /* Ensures button has enough room */
    }

    .result-filter-frm .panel-heading {
        cursor: pointer;
        background: #0a1828 !important;
        color: #fff !important;
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 15px 20px;
    }

    .result-filter-frm .panel-heading::after {
        content: '\f078';
        font-family: "Font Awesome 5 Free", "FontAwesome";
        font-weight: 900;
        transition: transform 0.3s ease;
    }

    .result-filter-frm.is-open .panel-heading::after {
        transform: rotate(180deg);
    }
}




.bootstrap-realtypress .rps-favorites .rps-favorites-result .rps-remove-favorite {color:#fff !important;}
.rps-single-listing-information-link {color:#aaa !important;}

/* Sticky sidebar for RealtyPress single listing */
.bootstrap-realtypress {margin:0 !important;}
.mw_sidebar_container {}
.mw_sidebar_inner {
    position: sticky;
    top: 00px; /* adjust for header height */
    align-self: flex-start;
    margin-bottom:10px;
}

@media (max-width: 768px) {
  #page {overflow: hidden;} 
}
@media (min-width: 769px) {
  #page {overflow: visible;} 
  .single-rps_listing .rps-single-listing .row > .col-md-3.col-sm-4.col-xs-12, 
  .page-id-9514 .col-md-3.col-sm-4.col-xs-12,
  .post-type-archive-rps_listing .row-property-result .col-md-3.col-sm-4.col-xs-12  {
    position: sticky !important;
    top: 00px; /* adjust for header height */
    align-self: flex-start;
    margin-bottom:10px;
  }


}



/* MULTI-STEP FORM */
/* FORM CARD CONTAINER */
.mh-form-card {
    background: #ffffff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    border: 1px solid #eee;
}

/* PROGRESS BAR */
.mh-steps {
    display: flex;
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}
.mh-steps .step {
    flex: 1;
    font-size: 14px;
    color: #999;
    font-weight: 600;
    display: flex;
    align-items: center;
}
.mh-steps .step span {
    width: 24px;
    height: 24px;
    background: #eee;
    color: #666;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    font-size: 12px;
}
.mh-steps .step.active { color: #0a1828; }
.mh-steps .step.active span { background: #c5a059; color: #fff; }

/* INPUTS */
.mh-multistep-form h5 { font-size: 22px; color: #0a1828; margin: 0 0 5px 0; }
.mh-form-header { margin-bottom: 25px; }
.mh-form-header p { color: #777; font-size: 14px; margin: 0; }

.mh-multistep-form input[type="text"],
.mh-multistep-form input[type="email"],
.mh-multistep-form input[type="tel"],
.mh-multistep-form select,
.mh-multistep-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fdfdfd;
    margin-bottom: 15px;
    font-size: 15px;
    transition: 0.3s;
}

.mh-multistep-form input:focus { border-color: #c5a059; outline: none; box-shadow: 0 0 0 3px rgba(197, 160, 89, 0.1); }

/* GRID */
.mh-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
@media (max-width: 600px) { .mh-grid { grid-template-columns: 1fr; } }

/* BUTTONS */
.mh-next-btn, .mh-submit {
    background: #0a1828;
    color: #fff;
    border: none;
    padding: 16px 30px;
    border-radius: 6px;
    font-weight: 700;
    cursor: pointer;
    width: 100%;
    font-size: 16px;
    transition: 0.3s;
}
.mh-next-btn:hover, .mh-submit:hover { background: #c5a059; }

.mh-prev-btn {
    background: none;
    border: none;
    color: #888;
    cursor: pointer;
    font-weight: 600;
}

/* STEPS LOGIC */
.mh-step { display: none; }
.mh-step.active { display: block; animation: fadeIn 0.4s; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* RADIO GROUPS */
.mh-radio-label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 8px; color: #0a1828; }
.wpcf7-list-item { margin: 0 15px 0 0; }

@media (max-width: 460px) {
.val-container {padding:0 !important;}
.mh-form-card {padding:20px !important;}
}








/* LOW COMISSION PAGE */

:root {
    --primary-gold: #c5a059;
    --dark-navy: #0a1828;
    --light-bg: #f8f9fa;
    --white: #ffffff;
    --text-dark: #333333;
}

.lp-container {
    font-family: 'Montserrat', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(rgba(10, 24, 40, 0.8), rgba(10, 24, 40, 0.8)), url('https://images.unsplash.com/photo-1560518883-ce09059eeffa?ixlib=rb-1.2.1&auto=format&fit=crop&w=1350&q=80');
    background-size: cover;
    background-position: center;
    padding: 100px 20px;
    text-align: center;
    color: var(--white);
}

.hero-section h1 {
    font-size: 3rem;
    color: var(--primary-gold);
    margin-bottom: 10px;
    text-transform: uppercase;
}

.hero-section p {
    font-size: 1.25rem;
    max-width: 800px;
    margin: 0 auto 30px;
}

.cta-button {
    background-color: var(--primary-gold);
    color: var(--white);
    padding: 15px 40px;
    text-decoration: none;
    font-weight: bold;
    border-radius: 5px;
    display: inline-block;
    transition: 0.3s;
}

.cta-button:hover {
    background-color: #b08d4a;
    transform: translateY(-3px);
}

/* Features Grid */
.features-section {
    padding: 60px 20px;
    background: var(--white);
    text-align: center;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    max-width: 1100px;
    margin: 40px auto;
}

.feature-card {
    padding: 30px;
    background: var(--light-bg);
    border-bottom: 4px solid var(--primary-gold);
    border-radius: 8px;
}

.feature-card h3 {
    color: var(--dark-navy);
    margin-top: 0;
}

/* Steps Section */
.steps-section {
    background: var(--dark-navy);
    color: var(--white);
    padding: 60px 20px;
    text-align: center;
}

.steps-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
}

.step-box {
    background: rgba(255,255,255,0.05);
    padding: 30px;
    border-radius: 10px;
    flex: 1;
    min-width: 280px;
    max-width: 350px;
    border: 1px solid var(--primary-gold);
}

.step-box span {
    font-size: 2rem;
    color: var(--primary-gold);
    display: block;
    margin-bottom: 10px;
}

/* Checklist Section */
.checklist-section {
    padding: 80px 20px;
    max-width: 900px;
    margin: 0 auto;
}

.checklist-section h2 {
    text-align: center;
    color: var(--dark-navy);
    margin-bottom: 40px;
}

.checklist-items {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.check-item {
    display: flex;
    align-items: center;
    font-size: 1.1rem;
}

.check-item:before {
    content: '✔';
    color: var(--primary-gold);
    margin-right: 15px;
    font-weight: bold;
}

.disclaimer {
    font-size: 0.85rem;
    color: #777;
    margin-top: 40px;
    text-align: center;
    font-style: italic;
}

@media (max-width: 768px) {
    .checklist-items { grid-template-columns: 1fr; }
    .hero-section h1 { font-size: 2rem; }
}






/* MORTAGE CALCULATOR */

.mortgage-form-fields label {
    display: block;
    font-weight: 700;
    font-size: 13px;
    color: #0a1828;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mortgage-form-fields input {
    margin-bottom: 20px !important;
    border: 2px solid #f0f0f0 !important;
    font-weight: 600;
}

.mortgage-form-fields input:focus {
    border-color: #c5a059 !important;
    background: #fff !important;
}

/* Specific styling for the result numbers */
#display-payment {
    text-shadow: 2px 2px 0px rgba(0,0,0,0.2);
    animation: pulse 1.5s infinite ease-in-out;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); color: #c5a059; }
    100% { transform: scale(1); }
}











/* ================================
   BLOG LAYOUT
================================ */

.blog-container {
  max-width: 1200px;
  margin: auto;
  padding: 40px 20px;
}

/* Hero */
.blog-hero,
.archive-header {
  text-align: center;
  margin-bottom: 50px;
}

.blog-hero h1,
.archive-header h1 {
  font-size: 2.4rem;
}

.blog-hero p {
  max-width: 720px;
  margin: 10px auto 0;
  color: #555;
}

/* ================================
   BLOG GRID
================================ */

.blog-grid {
  display: grid;
  gap: 32px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

/* Desktop */
@media (min-width: 1200px) {
  .blog-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Tablet */
@media (min-width: 768px) and (max-width: 1199px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile */
@media (max-width: 767px) {
  .blog-grid {
    grid-template-columns: 1fr;
  }
}

/* LIST VIEW */
.blog-grid.list-view {
  grid-template-columns: 1fr;
}

.blog-grid.list-view .post-card {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
}

.blog-grid.list-view .post-thumb img {
  height: 100%;
  min-height: 180px;
}

@media (max-width: 767px) {
  .blog-grid.list-view .post-card {
    grid-template-columns: 1fr;
  }
}


/* ================================
   POST CARD
================================ */

.post-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
  transition: transform .25s ease, box-shadow .25s ease;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.post-thumb img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.post-card-content {
  padding: 22px;
}

.post-card h2 {
  font-size: 1.15rem;
  margin: 10px 0;
}

.post-meta {
  font-size: 12px;
  color: #777;
}

/* ================================
   FEATURED POST
================================ */

.featured-post {
  position: relative;
  margin-bottom: 50px;
}

.featured-post img {
  width: 100%;
  border-radius: 16px;
}

.featured-content {
  position: absolute;
  bottom: 30px;
  left: 30px;
  max-width: 60%;
  color: #fff;
}

.featured-content span {
  display: inline-block;
  background: #000;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12px;
  margin-bottom: 10px;
}

/* ================================
   BLOG TOOLBAR
================================ */

.blog-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 30px 0;
  gap: 15px;
}

.blog-toolbar-left {
  display: flex;
  gap: 8px;
}

.blog-toolbar button {
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  background: #fff;
  font-weight: 600;
  cursor: pointer;
}

.blog-toolbar button.active {
  background: #111;
  color: #fff;
}

.blog-toolbar select {
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

/* ================================
   PAGINATION
================================ */

.pagination {
  margin: 60px 0;
  text-align: center;
}

.pagination a,
.pagination span {
  display: inline-block;
  margin: 0 6px;
  padding: 10px 14px;
  border-radius: 6px;
  background: #eee;
}

.pagination .current {
  background: #111;
  color: #fff;
}

/* ================================
   SINGLE POST LAYOUT
================================ */

.single-post-layout {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 40px;
}

@media (max-width: 991px) {
  .single-post-layout {
    grid-template-columns: 1fr;
  }
}

.single-featured-image img {
  width: 100%;
  border-radius: 12px;
  margin: 20px 0;
}

.single-content {
  line-height: 1.8;
}

/* ================================
   SIDEBAR (THEME NORMALIZED)
================================ */
/* ================================
   SIDEBAR (THEME NORMALIZED)
================================ */

/* Sticky container - apply this class to your sidebar column in Elementor/PHP */
.blog-sidebar, 
.rps-sidebar-col {
  position: sticky;
  top: 155px; /* Adjusted to clear your 135px header + gap */
  align-self: flex-start;
}

/* Unified widget container */
.sidebar-widget, 
.blog-bottom-widget,
.blog-sidebar .panel {
    background: #fff !important;
    border: 1px solid #eee;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.06);
    margin-bottom: 30px;
    overflow: hidden; /* Clips the background to the border radius */
}

/* Widget Titles - Navy Background with Gold Accent */
.sidebar-widget h4, 
.blog-bottom-widget h4,
.blog-sidebar .panel-heading {
    background: #0a1828 !important; /* Navy */
    color: #fff !important;
    padding: 12px 15px !important;
    font-size: 16px !important;
    font-weight: 700;
    text-transform: uppercase;
    margin: 0 0 15px 0 !important;
    border-left: 4px solid #c5a059 !important; /* Gold accent */
    border-bottom: none !important;
}

/* Inner padding for widget content */
.sidebar-widget > *:not(h4),
.blog-bottom-widget > *:not(h4) {
    padding: 0 20px 20px 20px;
}

/* Reset plugin specific widget internal styles */
.blog-sidebar .widget,
.blog-sidebar .panel-body {
  background: none !important;
  border: none !important;
  padding: 0 20px 20px 20px !important;
  box-shadow: none !important;
}

/* Disable sticky on mobile */
@media (max-width: 991px) {
  .blog-sidebar, 
  .rps-sidebar-col {
    position: relative;
    top: 0;
  }
}

/* ================================
   NEWSLETTER (CARD STYLE)
================================ */

.post-card.newsletter-card,
.newsletter-inline {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
  padding: 32px;
  text-align: center;
}

/* Icon */
.post-card.newsletter-card::before,
.newsletter-inline::before {
  content: "✉️";
  font-size: 40px;
  display: block;
  margin-bottom: 15px;
}

/* Text */
.newsletter-card h2,
.newsletter-inline h3 {
  font-size: 1.5rem;
  margin-bottom: 10px;
}

.newsletter-card p,
.newsletter-inline p {
  color: #555;
  margin-bottom: 20px;
}

/* Newsletter plugin */
.tnp {
  max-width: 100%;
}

.tnp-field-email input {
  width: 100%;
  padding: 14px;
  border-radius: 6px;
  border: 1px solid #ddd;
}

.tnp-submit {
  width: 100%;
  padding: 14px;
  margin-top: 10px;
  background: #111;
  color: #fff;
  border-radius: 6px;
  border: none;
  font-weight: 600;
  cursor: pointer;
}

.tnp-submit:hover {
  background: #000;
}

/* ================================
   AUTHOR + NAVIGATION
================================ */

.author-box {
  display: flex;
  gap: 15px;
  padding: 30px;
  background: #f8f8f8;
  border-radius: 12px;
  margin-top: 50px;
}

.post-navigation {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin: 60px 0;
}

.post-navigation a {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 45%;
}

.post-navigation img {
  border-radius: 50%;
  width: 60px;
  height: 60px;
  object-fit: cover;
}





/* Sidebar CTA Buttons */
/* Hide the first sidebar widget to prevent ghosting/spacing issues */
.right-sidebar .sidebar-widget:first-of-type {
    display: none !important;
}

/* --- CTA Grid Layout --- */
.custom-sidebar-ctas {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important; /* Force 4 columns */
    gap: 8px;
    margin: 20px 0;
    width: 100%;
}

/* Force grid to ignore any empty P or BR tags WordPress injects */
.custom-sidebar-ctas > p, 
.custom-sidebar-ctas > br {
    display: none !important;
}

/* --- The Button Style --- */
.bootstrap-realtypress .custom-sidebar-ctas a.cta-btn,
.custom-sidebar-ctas a.cta-btn {
    display: flex !important;
    align-items: center;
    justify-content: center;
    padding: 12px 5px !important;
    background-color: #D30023 !important;
    border: 2px solid #D30023 !important;
    color: #FFFFFF !important;
    text-decoration: none !important;
    font-weight: 700;
    font-size: 11px !important; /* Smaller for 4-in-a-row */
    text-transform: uppercase !important;
    border-radius: 4px;
    transition: all 0.3s ease;
    position: relative;
    min-width: 0; /* Prevents overflow */
}

/* FontAwesome Icon Styling (White) */
.custom-sidebar-ctas a.cta-btn i {
    position: absolute;
    left: 8px;
    font-size: 14px;
    color: #FFFFFF !important;
    font-style: normal;
}

.cta-text {
    width: 100%;
    text-align: center;
    padding-left: 15px;
}

/* --- Hover State --- */
.bootstrap-realtypress .custom-sidebar-ctas a.cta-btn:hover {
    background-color: transparent !important;
    color: #D30023 !important;
}

.custom-sidebar-ctas a.cta-btn:hover i {
    color: #D30023 !important;
}

/* --- Responsive Breakpoints --- */

/* Tablet: 2x2 */
@media (max-width: 1024px) {
    .custom-sidebar-ctas {
        grid-template-columns: 1fr 1fr !important;
    }
    .custom-sidebar-ctas a.cta-btn {
        font-size: 13px !important;
    }
}

/* Mobile: 1 Column Stacked */
@media (max-width: 767px) {
    .custom-sidebar-ctas {
        grid-template-columns: 1fr !important;
    }
    .custom-sidebar-ctas a.cta-btn {
        font-size: 15px !important;
        padding: 15px !important;
    }
}

/* Tablet: 2 by 2 (Between 768px and 1024px) */
@media (max-width: 1024px) {
    .custom-sidebar-ctas {
        grid-template-columns: 1fr 1fr;
    }
}

/* Mobile: 1 Column (Below 767px) */
@media (max-width: 767px) {
    .custom-sidebar-ctas {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .custom-sidebar-ctas a.cta-btn {
        font-size: 15px;
        padding: 15px 10px;
    }
}

/* --- Lightbox Overlay --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 24, 40, 0.9); /* Dark Navy Overlay */
    z-index: 99999;
    display: none;
    justify-content: center;
    align-items: flex-start; /* Align to top for better mobile scrolling */
    padding: 20px;
    overflow-y: auto; /* Allows background scroll if needed */
}

/* --- Modal Container --- */
.modal-inner {
    background: #fff;
    border-radius: 12px;
    position: relative;
    max-width: 500px;
    width: 100%;
    margin: 40px auto; /* Space from top */
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
    display: flex;
    flex-direction: column;
    max-height: 85vh; /* Prevents disappearing off-screen */
}

/* --- Sticky Modal Header --- */
.modal-header {
    padding: 20px 40px 15px 25px;
    background: #fff;
    border-bottom: 2px solid #c5a059; /* Gold accent */
    border-radius: 12px 12px 0 0;
    position: sticky;
    top: 0;
    z-index: 10;
}

.modal-header h3 {
    margin: 0;
    color: #0a1828;
    font-size: 1.2rem;
}

/* --- Scrollable Form Area --- */
.modal-body {
    padding: 25px;
    overflow-y: auto; /* This makes the form scrollable */
    flex-grow: 1;
    -webkit-overflow-scrolling: touch;
}

/* --- Fixed Close Button --- */
.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    color: #0a1828;
    z-index: 11;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eee;
    border-radius: 50%;
}

/* --- Mobile Specific Fixes --- */
@media (max-width: 767px) {
    .modal-overlay {
        padding: 10px;
    }
    .modal-inner {
        margin: 20px auto;
        max-height: 90vh;
    }
    
    /* CTA Reordering on Mobile */
    .rps-property-single-header {
        display: flex;
        flex-direction: column;
    }
    .sidebar-ctas-mobile {
        order: 2;
        margin-top: 15px;
    }
    .rps-pricing {
        order: 1;
    }
}















/* ===============================
   RealtyPress Gallery – FINAL
   =============================== */

.rps-gallery-main {
	position: relative;
	background: #f7f7f7;
	border-radius: 10px;
	overflow: hidden;
	box-shadow: 0 10px 28px rgba(0,0,0,.08);
}

.rps-gallery-main img {
	width: 100%;
	height: auto;
	display: block;
	object-fit: contain;
}

/* SOLD */
.rps-ribbon-sold {
	position: absolute;
	top: 15px;
	left: -40px;
	background: #d30023;
	color: #fff;
	padding: 6px 45px;
	transform: rotate(-45deg);
	font-size: 12px;
	font-weight: 700;
	z-index: 5;
}

/* THUMBNAILS */
.rps-gallery-thumbs {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 10px;
	height: 100%;
	overflow-y: auto;
}

@media (max-width: 991px) {
	.rps-gallery-thumbs {
		display: flex;
		grid-template-columns: none;
		overflow-x: auto;
		overflow-y: hidden;
		gap: 8px;
		padding-top: 12px;
	}
}

/* THUMB */
.rps-thumb {
	position: relative;
	padding: 0;
	border: 2px solid transparent;
	border-radius: 6px;
	background: #ddd;
	cursor: pointer;
	overflow: hidden;
	transition: border-color .2s ease;
	flex: 0 0 auto;
	width: 100%;
}

@media (max-width: 991px) {
	.rps-thumb {
		width: 80px;
	}
}

.rps-thumb::before {
	content: '';
	display: block;
	padding-top: 100%;
}

.rps-thumb img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	opacity: .7;
	transition: opacity .2s ease;
}

.rps-thumb:hover img,
.rps-thumb.active img {
	opacity: 1;
}

.rps-thumb.active {
	border-color: #c5a059;
}

.rps-gallery-main {
    position: relative; /* Ensure this is relative */
}

/* Full Height Navigation Overlays */
.rps-nav-btn {
    position: absolute;
    top: 0;
    height: 100%;
    width: 15%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    cursor: pointer;
    user-select: none;
    transition: background 0.3s ease;
}

.prev-btn { left: 0; }
.next-btn { right: 0; }

.rps-nav-btn span {
    color: #fff;
    font-size: 24px;
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s ease, background 0.3s ease;
}

.rps-gallery-main:hover .rps-nav-btn span {
    opacity: 1;
}

.rps-nav-btn:hover span {
    background: rgba(255,255,255,0.3);
}

/* Height Constraint for Thumbs */
@media (min-width: 992px) {
    .rps-gallery-thumbs {
        max-height: 0; /* Will be set by JS to match main image exactly */
        height: 100%;
    }
}

@media (max-width: 991px) {
    .rps-property-photo-row {
        overflow: hidden !important;
        /* Force the row to stay put */
        display: block !important; 
    }

    .rps-gallery-thumbs {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        gap: 8px;
        padding: 12px 0px;
        /* Key fix: Use max-width to prevent container from stretching the page */
        max-width: 100%; 
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
    }

    .rps-thumb {
        flex: 0 0 80px !important;
        width: 80px !important;
        scroll-snap-align: center;
    }
}