.rm-grade-badge{display:inline-block;margin:0 0 10px 0;padding:6px 10px;border-radius:999px;border:1px solid #dcdcde;background:#f6f7f7;font-size:12px}
.rm-grade-badge.rm-commercial{background:#fff3cd;border-color:#ffeeba}
.rm-grade-badge.rm-personal{background:#e7f5ff;border-color:#b3e5ff}

.rm-price-box{display:flex;justify-content:space-between;align-items:center;gap:10px;margin:0 0 12px 0;padding:12px 14px;border:1px solid #dcdcde;border-radius:14px;background:#fff}
.rm-price-label{font-weight:600;color:#646970}
.rm-price-value{font-weight:800}
.rm-per{font-weight:400;color:#646970;margin-left:4px}

.rm-calendar .rm-date-chips{margin-top:0;}
.rm-chip{display:inline-block;background:#f0f0f1;border:1px solid #dcdcde;border-radius:999px;padding:4px 10px;margin:4px;font-size:12px}

.rm-form p{margin:10px 0}
.rm-form input[type="text"], .rm-form input[type="number"], .rm-form textarea, .rm-form select{width:100%;max-width:720px;padding:10px;border:1px solid #dcdcde;border-radius:10px;background:#fff}
.rm-price-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;max-width:720px}
@media (max-width:640px){.rm-price-grid{grid-template-columns:1fr}}

.rm-submit-rental .notice, .rm-edit-rental .notice{padding:12px;border-radius:10px;margin:12px 0;background:#fff;border:1px solid #dcdcde}
.rm-submit-rental .notice-success, .rm-edit-rental .notice-success{border-left:4px solid #00a32a}
.rm-submit-rental .notice-error, .rm-edit-rental .notice-error{border-left:4px solid #d63638}

/* MaineTourism-inspired listings layout */
.rm-listing-shell{display:block;gap:24px;align-items:start}
@media (max-width:960px){.rm-listing-shell{grid-template-columns:1fr}}
.rm-sidebar{position:sticky;top:16px}
@media (max-width:960px){.rm-sidebar{position:static}}
.rm-sidebar-card{background:#fff;border:1px solid #dcdcde;border-radius:14px;padding:16px;margin-bottom:16px}
.rm-sidebar-card h3{margin:0 0 10px 0}
.rm-filter-form label{display:block;font-weight:600;margin:10px 0 6px}
.rm-filter-form input[type="text"], .rm-filter-form input[type="number"], .rm-filter-form select{width:100%;max-width:100%}
.rm-filter-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.rm-small{margin:6px 0 10px;color:#646970}

.rm-results{min-width:0}
.rm-results-header{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin:6px 0 14px}
.rm-results-header h2{margin:0}
.rm-results-count{color:#646970}
.rm-card-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
@media (max-width:1200px){.rm-card-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}}
@media (max-width:640px){.rm-card-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}}
.rm-card{background:#fff;border:1px solid #dcdcde;border-radius:16px;overflow:hidden;box-shadow:0 1px 0 rgba(0,0,0,.03)}
.rm-card-link{display:block;color:inherit;text-decoration:none}
.rm-card-media{height:180px;background-size:cover;background-position:center;background-color:#f6f7f7;display:flex;align-items:center;justify-content:center}
.rm-card-fallback{font-size:12px;color:#646970}
.rm-card-body{padding:14px 14px 16px}
.rm-card-meta{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:8px}
.rm-pill{display:inline-flex;align-items:center;gap:6px;font-size:12px;padding:6px 10px;border-radius:999px;border:1px solid #dcdcde;background:#f6f7f7}
.rm-pill-personal{background:#e7f5ff;border-color:#b3e5ff}
.rm-pill-commercial{background:#fff3cd;border-color:#ffeeba}
.rm-price{font-weight:700}
.rm-card-title{margin:0 0 6px 0;font-size:16px;line-height:1.2}
.rm-card-excerpt{margin:0;color:#3c434a}
.rm-pagination{display:flex;gap:8px;flex-wrap:wrap;margin:18px 0}
.rm-page{display:inline-flex;align-items:center;justify-content:center;min-width:36px;height:36px;border-radius:10px;border:1px solid #dcdcde;background:#fff;text-decoration:none}
.rm-page-current{background:#f6f7f7;font-weight:700}

/* Dashboard */
.rm-tabs{display:flex;gap:10px;margin:10px 0 16px;flex-wrap:wrap}
.rm-tabs a{padding:8px 12px;border:1px solid #dcdcde;border-radius:999px;text-decoration:none;background:#fff}
.rm-tabs a.active{background:#f6f7f7;font-weight:700}
.rm-dashboard-actions{margin:10px 0 14px}
.rm-table{width:100%;border-collapse:collapse}
.rm-table th,.rm-table td{border-bottom:1px solid #dcdcde;padding:10px;text-align:left}


/* Single rental layout */
.rm-single-listing{max-width:1200px;margin:0 auto}
.rm-single-hero{margin-bottom:16px}
.rm-single-hero img{width:100%;height:auto;border-radius:18px}
.rm-single-body{background:#fff;border:1px solid #dcdcde;border-radius:18px;padding:20px}
.rm-single-header{display:flex;flex-wrap:wrap;justify-content:space-between;gap:14px;margin-bottom:16px}
.rm-single-title{margin:0;font-size:28px;line-height:1.2}
.rm-single-meta{display:flex;align-items:center;gap:10px}
.rm-single-description{font-size:15px;line-height:1.6}


/* v7.6 Single Listing Sidebar Layout */
.rm-single-wrap{display:grid;grid-template-columns:1fr 360px;gap:24px;max-width:1200px;margin:0 auto}
@media(max-width:960px){.rm-single-wrap{grid-template-columns:1fr}}
.rm-single-main{display:grid;grid-template-columns:360px 1fr;gap:24px}
@media(max-width:960px){.rm-single-main{grid-template-columns:1fr}}
.rm-single-image img{width:100%;border-radius:14px}
.rm-single-gallery{width:100%}
.rm-gallery-main{position:relative}
.rm-gallery-main-link{display:block;border-radius:14px;overflow:hidden}
.rm-gallery-main-link img{width:100%;height:auto;border-radius:14px;transition:transform .18s ease}
.rm-gallery-main-link:hover img{transform:scale(1.04)}
.rm-gallery-nav{position:absolute;top:50%;transform:translateY(-50%);border:0;background:rgba(0,0,0,.45);color:#fff;width:34px;height:34px;border-radius:999px;cursor:pointer;display:flex;align-items:center;justify-content:center;z-index:2}
.rm-gallery-nav.rm-prev{left:10px}
.rm-gallery-nav.rm-next{right:10px}
.rm-gallery-nav:focus{outline:2px solid #2271b1;outline-offset:2px}
.rm-gallery-thumbs{display:flex;gap:8px;margin-top:0;overflow-x:auto;padding-bottom:4px;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch}
.rm-gallery-thumb{border:1px solid #dcdcde;background:#fff;border-radius:10px;padding:0;cursor:pointer;flex:0 0 auto;scroll-snap-align:start}
.rm-gallery-thumb img{display:block;width:72px;height:72px;object-fit:cover;border-radius:10px}
.rm-gallery-thumb.is-active{border-color:#2271b1;box-shadow:0 0 0 2px rgba(34,113,177,.15)}
.rm-gallery{display:flex;gap:8px;margin-top:0;}
.rm-gallery img{width:64px;height:64px;object-fit:cover;border-radius:8px;border:1px solid #dcdcde}
.rm-single-sidebar{position:sticky;top:24px}
.rm-booking-box,.rm-favorite-box{background:#fff;border:1px solid #dcdcde;border-radius:14px;padding:16px;margin-bottom:16px}


/* Optional polish */
.rm-price{font-size:20px;font-weight:700}
.rm-pill{padding:6px 12px;border-radius:999px;font-size:13px}


/* Edit Listing layout */
.rm-edit-grid{display:grid;grid-template-columns:300px 1fr;gap:24px;max-width:1100px}
@media(max-width:900px){.rm-edit-grid{grid-template-columns:1fr}}
.rm-edit-left img{max-width:100%;border-radius:12px;margin-bottom:12px}
.rm-edit-right input,.rm-edit-right textarea,.rm-edit-right select{width:100%}
.rm-edit-actions{grid-column:1/-1;margin-top:0;}


/* v7.9.3 UX improvements */
.rm-dropzone-input{border:2px dashed #c3c4c7;padding:14px;border-radius:12px;background:#fafafa}
.rm-dropzone-input:hover{background:#f0f0f1}
.rm-price-preview{margin-top:0;font-size:14px}

.rm-edit-left small{display:block;color:#646970;margin-top:0;}
.rm-booking-form button:disabled{opacity:.6;cursor:not-allowed}

/* v8.2.x Visual Availability Calendar */
.rm-calendar-wrapper{border:1px solid #ddd;padding:10px;border-radius:8px;background:#fff}
.rm-calendar-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}
.rm-cal-month{font-weight:600}
.rm-cal-prev,.rm-cal-next{border:1px solid #ddd;background:#f7f7f7;border-radius:6px;padding:4px 10px;cursor:pointer}
.rm-cal-prev:hover,.rm-cal-next:hover{background:#f0f0f0}
.rm-calendar-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:6px;text-align:center}
.rm-cal-head{font-size:12px;font-weight:600;color:#444}
.rm-cal-day{border:1px solid #e3e3e3;background:#fff;border-radius:8px;padding:8px 0;cursor:pointer}
.rm-cal-day:hover{background:#eef6ff}
.rm-cal-disabled,.rm-cal-blocked{background:#f2f2f2 !important;color:#9a9a9a !important;border-color:#eee !important;cursor:not-allowed !important}
.rm-cal-selected{background:#2271b1 !important;color:#fff !important;border-color:#2271b1 !important}

/* Calendar color improvements */
.rm-cal-day {
  background:#dff0e1; /* light green for available */
  color:#2e7d32;
}

.rm-cal-day:hover {
  background:#c8e6c9;
}

.rm-cal-disabled,
.rm-cal-blocked {
  background:#f0f0f0 !important;
  color:#9e9e9e !important;
}

.rm-cal-selected {
  background:#1976d2 !important;
  color:#ffffff !important;
}

/* Calendar arrows */
.rm-calendar-header button {
  background:#1976d2;
  color:#ffffff;
  border:none;
  border-radius:4px;
  padding:4px 10px;
  cursor:pointer;
}

.rm-calendar-header button:hover {
  background:#125aa3;
}

/* Calendar legend */
.rm-calendar-legend {
  display:flex;
  gap:16px;
  margin-top:0;
  font-size:13px;
  align-items:center;
}

.rm-calendar-legend span {
  display:flex;
  align-items:center;
  gap:6px;
}

.rm-legend-box {
  width:14px;
  height:14px;
  border-radius:3px;
}

.rm-legend-available { background:#dff0e1; }
.rm-legend-booked { background:#f0f0f0; }

.rm-calendar-legend-inline {
  margin-top:0;
  justify-content:flex-start;
}

/* Calendar legend visibility enhancement */
.rm-calendar-legend .rm-legend-box {
  border: 1px solid #bdbdbd;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.03);
}

.rm-legend-available {
  border-color: #66bb6a; /* green border */
}

.rm-legend-booked {
  border-color: #bdbdbd; /* gray border */
}

/* Final enforced Available color */
.rm-cal-day.rm-available {
  background:#e6f4e6;
  color:#009900;
}

.rm-legend-available {
  background:#e6f4e6;
  border-color:#009900;
}

.rm-calendar-legend .rm-legend-available {
  color:#009900;
}

/* Legend-only Available color adjustment */
.rm-calendar-legend .rm-legend-available {
  background:#e6f4e6 !important;
  border-color:#009900 !important;
  color:#009900 !important;
}


/* --- Booking status badges + filters (v8.7.8) --- */
.rm-badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:3px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:700;
  line-height:1.4;
  border:1px solid #d9d9d9;
  background:#f5f5f5;
  white-space:nowrap;
}
.rm-badge-pending{background:#fff7e6;border-color:#fbbf24;color:#92400e;}
.rm-badge-approved{background:#eff6ff;border-color:#93c5fd;color:#1d4ed8;}
.rm-badge-paid{background:#e8f5e8;border-color:#86efac;color:#065f46;}
.rm-badge-picked_up{background:#e0f2fe;border-color:#7dd3fc;color:#0369a1;}
.rm-badge-returned{background:#f3f4f6;border-color:#d1d5db;color:#374151;}
.rm-badge-cancelled{background:#fee2e2;border-color:#fca5a5;color:#b91c1c;}

.rm-booking-filters{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin:10px 0 12px;
}
.rm-booking-filters .rm-filter{
  display:inline-block;
  padding:6px 10px;
  border:1px solid #d9d9d9;
  border-radius:999px;
  background:#fff;
  font-size:13px;
  text-decoration:none;
}
.rm-booking-filters .rm-filter.active{
  border-color:#2271b1;
  color:#2271b1;
  font-weight:700;
}

/* Deposit decision badges */
.rm-badge-green{ background:#e6f4ea; border-color:#b7e1c2; color:#1e7e34; }
.rm-badge-yellow{ background:#fff8e1; border-color:#ffe09a; color:#8a6d00; }
.rm-badge-red{ background:#fdecea; border-color:#f5c2c7; color:#b02a37; }

/* Inline star rating (dashboard) */
.rm-inline-rate-stars{ display:inline-block; margin:0; }
.rm-star-select{ display:inline-flex; gap:2px; align-items:center; }
.rm-star-btn{
  appearance:none;
  background:transparent;
  border:0;
  padding:0 2px;
  cursor:pointer;
  font-size:18px;
  line-height:1;
  color:#c4c4c4;
}
.rm-star-btn:hover,
.rm-star-btn:focus{ color:#f5c518; outline:none; }
.rm-star-btn.filled{ color:#f5c518; }
.rm-star-select.rated .rm-star{
  font-size:18px;
  line-height:1;
  color:#c4c4c4;
  padding:0 2px;
}
.rm-star-select.rated .rm-star.filled{ color:#f5c518; }


/* =========================
   Mobile Dashboard Enhancements
   ========================= */

@media (max-width:768px){

/* stack dashboard sections */
.rm-dashboard,
.rm-dashboard-grid{
display:flex!important;
flex-direction:column!important;
gap:14px;
}

/* cards full width */
.rm-card,
.rm-panel,
.rm-box{
width:100%!important;
margin:0!important;
}

/* tables → card layout */
.rm-dashboard table,
.rm-table{
display:block;
width:100%;
border:0;
}

.rm-dashboard table thead{
display:none;
}

.rm-dashboard table tr{
display:block;
background:#fff;
border:1px solid #e5e7eb;
border-radius:14px;
padding:12px;
margin-bottom:12px;
box-shadow:0 2px 6px rgba(0,0,0,.05);
}

.rm-dashboard table td{
display:flex;
justify-content:space-between;
padding:6px 0;
font-size:14px;
}

/* buttons */
.rm-dashboard .button,
.rm-dashboard button{
width:100%;
padding:12px;
font-size:16px;
border-radius:12px;
}

/* headings */
.rm-dashboard h1,
.rm-dashboard h2,
.rm-dashboard h3{
font-size:20px;
}

/* spacing */
.rm-dashboard{
padding:10px;
}

}

/* touch targets */
.rm-dashboard a,
.rm-dashboard button{
min-height:44px;
display:flex;
align-items:center;
justify-content:center;
}


/* Sticky Mobile Action Bar */
@media(max-width:768px){
.rm-sticky-bar{
position:fixed;
bottom:0;
left:0;
right:0;
background:#fff;
border-top:1px solid #ddd;
display:flex;
z-index:9999;
box-shadow:0 -2px 10px rgba(0,0,0,.08);
}
.rm-sticky-bar a{
flex:1;
text-align:center;
padding:12px 6px;
font-size:14px;
font-weight:600;
text-decoration:none;
color:#111;
}
.rm-sticky-bar a.primary{
background:#111;
color:#fff;
}
body{padding-bottom:70px;}
}


/* =========================
   Mobile Auto-Fit Layout Fix
   Prevent squished left columns/rows
   ========================= */
@media (max-width:768px){

/* ensure full-width containers */
.rm-dashboard,
.rm-dashboard * ,
.rm-dashboard-grid,
.rm-dashboard-grid *{
box-sizing:border-box !important;
}

.rm-dashboard,
.rm-dashboard-grid{
width:100% !important;
max-width:100% !important;
margin-left:auto !important;
margin-right:auto !important;
}

/* kill floats / fixed widths on columns */
.rm-dashboard [class*="col"],
.rm-dashboard [class*="column"],
.rm-dashboard .rm-col,
.rm-dashboard .rm-column,
.rm-dashboard .rm-card,
.rm-dashboard .rm-panel,
.rm-dashboard .rm-box{
float:none !important;
width:100% !important;
max-width:100% !important;
flex:0 0 100% !important;
}

/* if there is a row/grid wrapper, wrap properly */
.rm-dashboard [class*="row"],
.rm-dashboard .rm-row,
.rm-dashboard .rm-grid,
.rm-dashboard-grid{
display:flex !important;
flex-wrap:wrap !important;
align-items:stretch !important;
justify-content:stretch !important;
gap:14px;
}

/* tables + long content should not overflow left */
.rm-dashboard table,
.rm-dashboard .rm-table{
width:100% !important;
max-width:100% !important;
overflow:hidden;
}

.rm-dashboard table tr{
width:100% !important;
}

.rm-dashboard table td{
min-width:0;
word-break:break-word;
}

/* sometimes themes apply negative margins */
.rm-dashboard .container,
.rm-dashboard .content-area,
.rm-dashboard .site-content,
.rm-dashboard .entry-content{
margin-left:0 !important;
margin-right:0 !important;
padding-left:0 !important;
padding-right:0 !important;
}

/* prevent horizontal scrolling */
html, body{
overflow-x:hidden;
}

}


/* MOBILE FIX — RENTER DASHBOARD TABLE */
@media (max-width:768px){

  .rm-my-bookings,
  .rm-renter-bookings,
  .rm-bookings-table{
    width:100% !important;
    max-width:100% !important;
    overflow:hidden;
  }

  .rm-bookings-table table,
  .rm-bookings-table tbody,
  .rm-bookings-table tr,
  .rm-bookings-table td{
    display:block !important;
    width:100% !important;
  }

  .rm-bookings-table tr{
    margin-bottom:14px;
    border-radius:12px;
    background:#fff;
    box-shadow:0 2px 8px rgba(0,0,0,.06);
    padding:12px;
  }

  .rm-bookings-table thead{
    display:none !important;
  }

  .rm-bookings-table td{
    padding:6px 0 !important;
    border:none !important;
  }

  .rm-bookings-table .button,
  .rm-bookings-table .rm-btn{
    width:100%;
    margin-top:0;
  }
}


/* MOBILE DASHBOARD FIX */
@media (max-width: 768px){

  .rm-dashboard-wrap,
  .rm-bookings-wrap{
    width:100% !important;
    max-width:100% !important;
    padding:10px !important;
    margin:0 !important;
  }

  .rm-booking-row,
  .rm-booking-card{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    margin-bottom:12px;
  }

  .rm-booking-col{
    display:block !important;
    width:100% !important;
    border-right:none !important;
  }

  .rm-booking-row *{
    min-width:0 !important;
    box-sizing:border-box;
    word-break:break-word;
  }

  .rm-booking-row .button,
  .rm-booking-row .rm-btn{
    width:100%;
    text-align:center;
    margin-top:0;
  }

  .rm-dashboard-search input,
  .rm-dashboard-search button{
    width:100% !important;
  }
}


/* MOBILE FIX — OWNER BOOKINGS TABLE (.rm-table) */
@media (max-width:768px){

  .rm-dashboard{width:100% !important; max-width:100% !important; padding:10px !important; margin:0 !important;}

  /* Search bar in bookings tab */
  .rm-dashboard .rm-booking-search{display:block !important; width:100% !important;}
  .rm-dashboard .rm-booking-search input[type="text"]{width:100% !important; min-width:0 !important; box-sizing:border-box;}
  .rm-dashboard .rm-booking-search .button{width:100% !important; margin-top:0;}

  /* Turn the owner bookings table into stacked cards */
  .rm-dashboard .rm-table,
  .rm-dashboard .rm-table thead,
  .rm-dashboard .rm-table tbody,
  .rm-dashboard .rm-table tr,
  .rm-dashboard .rm-table th,
  .rm-dashboard .rm-table td{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    box-sizing:border-box;
  }

  .rm-dashboard .rm-table thead{display:none !important;}

  .rm-dashboard .rm-table tr{
    margin:0 0 14px 0 !important;
    border:1px solid #e5e7eb;
    border-radius:12px;
    background:#fff;
    box-shadow:0 2px 8px rgba(0,0,0,.06);
    padding:12px;
  }

  .rm-dashboard .rm-table td{
    border:none !important;
    border-top:1px solid #f1f5f9 !important;
    padding:8px 0 !important;
  }

  .rm-dashboard .rm-table td:first-child{border-top:none !important;}

  /* Buttons inside action column */
  .rm-dashboard .rm-table .button,
  .rm-dashboard .rm-table .rm-btn{
    width:100% !important;
    display:block !important;
    text-align:center;
    margin-top:0;
  }
}


/* HERO RESPONSIVE FIT */
.rm-hero,
.rm-hero-banner,
.rm-hero-wrap{
width:100%;
max-width:100%;
overflow:hidden;
}

.rm-hero img,
.rm-hero-banner img{
width:100%;
height:auto;
display:block;
object-fit:cover;
}

@media (min-width:768px){
.rm-hero,
.rm-hero-banner{
height:600px;
}
.rm-hero img,
.rm-hero-banner img{
height:100%;
object-fit:cover;
}
}


/* SUBMIT FORM — INLINE FIELD GROUPS */
.rm-inline-row{
  display:flex;
  gap:12px;
  align-items:flex-start;
  width:100%;
  margin: 0 0 14px 0;
}
.rm-inline-col{
  flex:1;
  min-width: 0;
}
.rm-inline-row select,
.rm-inline-row input[type="text"],
.rm-inline-row input[type="number"],
.rm-inline-row input[type="time"],
.rm-inline-row input[type="date"]{
  width:100%;
  box-sizing:border-box;
}
@media (max-width: 768px){
  .rm-inline-row{
    flex-direction:column;
    gap:10px;
  }
}


/* --- Hero Cleanup Patch --- */
.rm-hero-top-space,
.rm-mobile-filters,
.rm-filter-toggle,
.rm-mobile-menu,
.rm-mobile-toggle {
    display: none !important;
}

.rm-hero,
.rm-hero-container {
    margin-top: 0 !important;
    padding-top: 0 !important;
}



/* 4-column responsive grid */
@media (max-width: 1400px){
  .rm-card-grid{ grid-template-columns: repeat(3,minmax(0,1fr)); }
}
@media (max-width: 1024px){
  .rm-card-grid{ grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 600px){
  .rm-card-grid{ grid-template-columns: repeat(1,minmax(0,1fr)); }
}

/* Slightly smaller cards */
.rm-card{ padding:12px !important; }
.rm-card-media{ height:180px !important; }
.rm-card-title{ font-size:16px !important; }
.rm-price{ font-size:14px !important; }


/* Hover Overlay */
.rm-card-media{
  position:relative;
  overflow:hidden;
}
.rm-hover-overlay{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,0.55);
  display:flex;
  align-items:center;
  justify-content:center;
  opacity:0;
  transition:opacity .25s ease;
}
.rm-hover-overlay span{
  color:#fff;
  font-size:16px;
  font-weight:600;
  letter-spacing:.5px;
}
.rm-card:hover .rm-hover-overlay{
  opacity:1;
}



/* === Front Page Grid Repair (Sidebar + 4-col cards) === */
.rm-listing-shell{
  display:grid !important;
  grid-template-columns:240px 1fr !important;
  gap:24px !important;
  align-items:start !important;
  width:100% !important;
  max-width:1400px !important;
  margin:0 auto !important;
  padding:0 16px !important;
}
.rm-sidebar{width:100% !important;}
@media (max-width: 980px){
  .rm-listing-shell{grid-template-columns:1fr !important;}
  .rm-sidebar{order:2 !important;}
}
.rm-card-grid{
  display:grid !important;
  grid-template-columns:repeat(4, minmax(0, 1fr)) !important;
  gap:16px !important;
}
@media (max-width: 1200px){
  .rm-card-grid{grid-template-columns:repeat(3, minmax(0,1fr)) !important;}
}
@media (max-width: 900px){
  .rm-card-grid{grid-template-columns:repeat(2, minmax(0,1fr)) !important;}
}
@media (max-width: 560px){
  .rm-card-grid{grid-template-columns:repeat(1, minmax(0,1fr)) !important;}
}


/* ------------------------------------------------------------
   Front Page: Topbar + Full-width Explore Grid (Option 1)
   ------------------------------------------------------------ */

.rm-browse-page{width:100%}
.rm-browse-page .rm-results{min-width:0}

/* Replace old two-column shell behavior on front page */
.rm-browse-front{display:block}
.rm-browse-front .rm-results-header{margin-top:10px}

/* Topbar */
.rm-topbar{position:relative; z-index:10; margin:0 0 14px 0}
.rm-topbar-form{display:flex; flex-wrap:wrap; gap:10px; align-items:center; justify-content:space-between}
.rm-topbar-search{display:flex; gap:10px; flex:1 1 520px; min-width:260px}
.rm-topbar-search input[type="text"]{width:100%; max-width:100%; padding:12px 14px; border:1px solid #dcdcde; border-radius:12px; font-size:16px}
.rm-topbar-controls{display:flex; gap:10px; flex:0 0 auto; align-items:center; flex-wrap:wrap}
.rm-topbar-select{padding:12px 12px; border:1px solid #dcdcde; border-radius:12px; font-size:14px; background:#fff; max-width:220px}
.rm-topbar-btn{padding:12px 14px; border-radius:12px; border:1px solid #dcdcde; background:#fff; cursor:pointer; font-size:14px; line-height:1}
.rm-topbar-btn-primary{background:#111; color:#fff; border-color:#111}
.rm-topbar-btn-ghost{background:#f6f7f7}

/* Mobile category pills (mobile only) */
.rm-cat-pills{display:none; gap:8px; overflow:auto; padding:8px 2px 2px; margin-top:6px; -webkit-overflow-scrolling:touch}
.rm-pill-link{display:inline-flex; align-items:center; white-space:nowrap; padding:8px 12px; border-radius:999px; border:1px solid #dcdcde; background:#fff; font-size:13px; text-decoration:none}
.rm-pill-link.is-active{background:#111; border-color:#111; color:#fff}

/* Drawer (Filters) */
.rm-drawer-overlay{position:fixed; inset:0; background:rgba(0,0,0,.45); z-index:9998; opacity:0; pointer-events:none; transition:opacity .18s ease}
.rm-drawer{position:fixed; top:0; right:-420px; width:420px; max-width:92vw; height:100%; background:#fff; z-index:9999; overflow:auto; padding:16px; transition:right .22s ease; box-shadow:-10px 0 30px rgba(0,0,0,.18)}
.rm-drawer-head{display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:12px}
.rm-drawer-title{font-weight:700; font-size:16px}
.rm-drawer-close{border:1px solid #dcdcde; background:#fff; border-radius:10px; padding:8px 10px; cursor:pointer}
body.rm-filter-open .rm-drawer{right:0}
body.rm-filter-open .rm-drawer-overlay{opacity:1; pointer-events:auto}

/* Drawer form */
.rm-filter-form-drawer input[type="text"],
.rm-filter-form-drawer input[type="number"],
.rm-filter-form-drawer select{width:100%; max-width:100%}
.rm-filter-form-drawer .rm-filter-row{display:grid; grid-template-columns:1fr 1fr; gap:10px}

/* Card media: use <img> rather than background-image */
.rm-card-media{position:relative; border-radius:14px; overflow:hidden; background:#f6f7f7}
.rm-card-img{display:block; width:100%; height:auto}

/* Hover overlay (CSS-only) on card link */
.rm-card-link{position:relative; display:block}
.rm-card-link::after{content:""; position:absolute; inset:0; background:rgba(0,0,0,.35); opacity:0; transition:opacity 160ms ease}
.rm-card-link::before{content:"View"; position:absolute; left:50%; top:50%; transform:translate(-50%,-50%); opacity:0; transition:opacity 160ms ease; padding:10px 14px; border-radius:999px; background:rgba(255,255,255,.92); color:rgba(0,0,0,.86); font-size:14px; font-weight:600}
.rm-card-link:hover::after, .rm-card-link:hover::before{opacity:1}

/* Mobile refinements */
@media (max-width:768px){
  .rm-topbar-form{gap:8px}
  .rm-topbar-search{flex:1 1 100%}
  .rm-topbar-controls{width:100%; justify-content:space-between}
  .rm-topbar-select{max-width:48%}
  .rm-cat-pills{display:flex}
  .rm-drawer{top:auto; bottom:-100%; left:0; right:0; width:100%; height:auto; max-height:78vh; border-radius:16px 16px 0 0; transition:bottom .22s ease; box-shadow:0 -10px 30px rgba(0,0,0,.18)}
  body.rm-filter-open .rm-drawer{bottom:0; right:0}
}

/* Make Explore grid full width regardless of any older shell constraints */
.rm-browse-front .rm-results{width:100%}


/* Sponsored / Ads */
.rm-pill-sponsored{display:inline-block;margin:0 0 10px 0;padding:6px 10px;border-radius:999px;border:1px solid #dcdcde;background:#fff3cd;font-size:12px}
.rm-card-ad .rm-ad-fallback{padding:18px;border:1px dashed #dcdcde;border-radius:12px;background:#f6f7f7}


/* ------------------------------------------------------------
   Remove white spacer bar above hero (front page only)
   ------------------------------------------------------------ */

#browse.rm-browse-front{
  margin-top:0 !important;
  padding-top:0 !important;
}

.rm-browse-front{
  margin-top:0 !important;
  padding-top:0 !important;
}

.rm-browse-front > *:first-child{
  margin-top:0 !important;
}

.rm-hero-top-space{
  display:none !important;
  height:0 !important;
  margin:0 !important;
  padding:0 !important;
}


/* --- Precise spacing for hero and bottom ad --- */

/* 10px space under hero banner */
.rm-hd-hero{
    margin-bottom:10px !important;
}

/* 10px space above bottom ad banner */
.rmfp-ad.rmfp-ad-front_bottom{
    margin-top:10px !important;
}



/* Improve visibility of Filters button to match theme primary color */
.rm-topbar-btn-ghost{
    background: var(--wp--preset--color--primary, #0073aa) !important;
    color:#ffffff !important;
    border-color: var(--wp--preset--color--primary, #0073aa) !important;
    font-weight:600;
}

.rm-topbar-btn-ghost:hover{
    opacity:0.9;
}


/* --- Mobile polish for topbar controls --- */
@media (max-width:768px){

    .rm-topbar-search input{
        padding:8px 10px !important;
        font-size:14px !important;
    }

    .rm-topbar-btn,
    .rm-topbar-btn-ghost,
    .rm-topbar-select{
        padding:8px 10px !important;
        font-size:13px !important;
        height:auto !important;
    }

    .rm-topbar{
        gap:6px !important;
    }

}

/* Improve visibility of drawer close button */
.rm-drawer-close{
    background:#ffffff !important;
    color:#111111 !important;
    border:1px solid #ccc !important;
    font-weight:700;
    padding:6px 10px !important;
    border-radius:4px !important;
}

.rm-drawer-close:hover{
    background:#f3f3f3 !important;
}

.rm-seller-link{font-weight:600;text-decoration:none}
.rm-seller-link:hover{text-decoration:underline}


/* v10.45 stable: owner rating stars */
.rm-inline-rate-stars,.rm-inline-rate{display:inline-block;margin:0}
.rm-star-select{display:inline-flex;gap:2px;align-items:center}
.rm-star-btn{
  appearance:none;
  background:transparent;
  border:0;
  padding:0 2px;
  cursor:pointer;
  font-size:20px;
  line-height:1;
  color:#c4c4c4;
}
.rm-star-btn:hover,
.rm-star-btn:focus,
.rm-star-btn.filled{
  color:#f5c518;
  outline:none;
}
.rm-star-select.rated .rm-star{
  font-size:20px;
  line-height:1;
  color:#c4c4c4;
  padding:0 2px;
}
.rm-star-select.rated .rm-star.filled{color:#f5c518}


/* v10.48 owner rating ajax UI */
.rm-inline-rate-stars,.rm-inline-rate{display:inline-block;margin:0}
.rm-star-select{display:inline-flex;gap:2px;align-items:center}
.rm-star-btn{
  appearance:none;
  background:transparent;
  border:0;
  padding:0 2px;
  cursor:pointer;
  font-size:22px;
  line-height:1;
  color:#c4c4c4;
}
.rm-star-btn:hover,
.rm-star-btn:focus,
.rm-star-btn.filled{
  color:#f5c518 !important;
  outline:none;
}
.rm-star-select.rated .rm-star{
  font-size:22px;
  line-height:1;
  color:#c4c4c4;
  padding:0 2px;
}
.rm-star-select.rated .rm-star.filled{
  color:#f5c518 !important;
}


/* v10.50 renter reputation */
.rm-renter-trust{margin-top:4px}
.rm-renter-badge{display:inline-block;padding:2px 8px;border-radius:999px;background:#f3f4f6}
.rm-renter-rate-form{display:flex;flex-direction:column;gap:6px;min-width:180px}
.rm-renter-star-row{display:flex;gap:2px;align-items:center}
.rm-renter-star-btn{
  appearance:none;background:transparent;border:0;padding:0 2px;cursor:pointer;
  font-size:20px;line-height:1;color:#c4c4c4;
}
.rm-renter-star-btn.filled,.rm-renter-star-btn:hover,.rm-renter-star-btn:focus{color:#f5c518 !important;outline:none}
.rm-renter-reason{max-width:220px}
.rm-renter-rate-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.rm-renter-rate-status{font-size:12px;color:#6b7280}
.rm-renter-rate-form.rated .rm-renter-rate-status{color:#166534;font-weight:600}


/* v10.563 actual front-page top/bottom ad slots */
.rm-frontpage-top-ad,
.rm-frontpage-bottom-ad{
    margin: 0 0 18px 0;
}
.rm-frontpage-bottom-ad{
    margin: 18px 0 0 0;
}
.rm-ad-card-grid{
    width:100%;
}
.rm-ad-card-grid .rm-ad-card-image,
.rm-ad-card-grid img{
    display:block;
    width:100%;
    height:auto;
    border-radius:12px;
}
.rm-ad-card-fallback{
    padding:18px;
    border:1px solid #e5e7eb;
    border-radius:12px;
    background:#fff;
    font-weight:600;
}


/* v10.586 printer icons for booking documents */
.rm-booking-doc-icons{
    display:flex;
    gap:8px;
    align-items:center;
    flex-wrap:wrap;
}

.rm-doc-print-icon{
    display:inline-flex;
    align-items:center;
    gap:4px;
    text-decoration:none;
    font-size:13px;
    border:none;
    background:none;
    padding:0;
}

.rm-doc-print-icon:hover{
    background:#f6f7f7;
}


.rm-doc-print-icon{
    display:inline-flex;
    align-items:center;
    gap:4px;
    text-decoration:none;
    font-size:13px;
    border:none;
    background:none;
    padding:0;
}

.rm-doc-print-icon span{
    font-size:13px;
}


/* v10.616 front page card spacing cleanup */
.rm-pro-card-title{
    margin-bottom: 2px !important;
}
.rm-pro-card-price-strong{
    margin-top: 0 !important;
}


/* v10.617 actual front card spacing/location cleanup */
.rm-card-title{
    margin-bottom: 2px !important;
}
.rm-card-body .rm-price,
.rm-price{
    margin-top: 0 !important;
}
.rm-card-location-text{
    margin-top: 4px !important;
    color: #666;
    font-size: 13px;
    line-height: 1.3;
}


/* v10.618 force front card city/state + spacing */
.rm-card-body .rm-card-title,
.rm-card-title,
.rm-pro-card-title{
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}
.rm-card-body .rm-price,
.rm-price,
.rm-pro-card-price-strong{
    margin-top: 0 !important;
    padding-top: 0 !important;
}
.rm-card-location-text,
.rm-card-meta,
.rm-pro-card-meta{
    display:block !important;
    visibility:visible !important;
}
.rm-card-location-text{
    margin-top:4px !important;
    color:#666 !important;
    font-size:13px !important;
    line-height:1.3 !important;
}


/* v10.619 tighter front card title / price / location styling */
.rm-card-body,
.rm-pro-card-body{
    padding-top: 10px !important;
}

.rm-card-title,
.rm-pro-card-title{
    margin: 2px 0 1px !important;
    padding: 0 !important;
    line-height: 1.18 !important;
    font-size: 16px !important;
    font-weight: 800 !important;
}

.rm-card-body .rm-price,
.rm-price,
.rm-pro-card-price-strong{
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1.18 !important;
    font-size: 15px !important;
    font-weight: 800 !important;
}

.rm-card-location-text,
.rm-card-meta,
.rm-pro-card-meta{
    margin-top: 2px !important;
    padding-top: 0 !important;
    line-height: 1.2 !important;
    font-size: 12.5px !important;
    color: #666 !important;
}

.rm-card-meta:empty{
    display:none !important;
}
