/* ============================================================
   BY Administration – Hostaway Booking  v3.0.0
   Single cohesive stylesheet. Brand: #213C85
   ============================================================ */

:root {
  --by-primary:       #213C85;
  --by-primary-dark:  #182c63;
  --by-primary-soft:  #eef2fb;
  --by-ink:           #0f1729;
  --by-text:          #1f2937;
  --by-muted:         #6b7280;
  --by-line:          #e6e8ef;
  --by-bg:            #ffffff;
  --by-bg-soft:       #f7f8fb;
  --by-success:       #16a34a;
  --by-success-bg:    #f0fdf4;
  --by-error:         #dc2626;
  --by-error-bg:      #fef2f2;
  --by-r-sm:          10px;
  --by-r:             16px;
  --by-r-lg:          22px;
  --by-shadow:        0 1px 3px rgba(15,23,42,.06), 0 8px 24px rgba(15,23,42,.06);
  --by-shadow-lg:     0 12px 40px rgba(15,23,42,.12);
  --by-font:          system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --by-ease:          .2s cubic-bezier(.4,0,.2,1);
  --by-maxw:          1240px;
}

/* ── Base ─────────────────────────────────────────────────────── */
.by-listings-wrap, .by-listing-detail, .by-modal { font-family: var(--by-font); color: var(--by-text); }
.by-listings-wrap *, .by-listing-detail *, .by-modal * { box-sizing: border-box; }
.by-listings-wrap a, .by-listing-detail a, .by-modal a { text-decoration: none; }
.by-listings-wrap, .by-listing-detail { max-width: var(--by-maxw); margin: 0 auto; }

/* ── Buttons ──────────────────────────────────────────────────── */
.by-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: inherit; font-size: 15px; font-weight: 600; line-height: 1.2;
  padding: 13px 24px; border-radius: var(--by-r-sm); border: 1.5px solid transparent;
  cursor: pointer; transition: transform var(--by-ease), background var(--by-ease), box-shadow var(--by-ease), color var(--by-ease);
  white-space: nowrap;
}
.by-btn:focus-visible { outline: 3px solid rgba(33,60,133,.4); outline-offset: 2px; }
.by-btn-primary { background: var(--by-primary); color: #fff; border-color: var(--by-primary); }
.by-btn-primary:hover { background: var(--by-primary-dark); border-color: var(--by-primary-dark); color: #fff; box-shadow: 0 8px 22px rgba(33,60,133,.25); transform: translateY(-1px); }
.by-btn-primary:disabled { opacity: .6; cursor: not-allowed; transform: none; box-shadow: none; }
.by-btn-outline { background: #fff; color: var(--by-primary); border-color: var(--by-line); }
.by-btn-outline:hover { border-color: var(--by-primary); background: var(--by-primary-soft); color: var(--by-primary); }
.by-btn-sm { font-size: 13px; padding: 9px 16px; }
.by-btn-full { width: 100%; }
.by-link-btn { background: none; border: none; color: var(--by-primary); font-size: 14px; font-weight: 600; cursor: pointer; padding: 0; text-decoration: underline; }

/* ── Filter bar ───────────────────────────────────────────────── */
.by-filters-airbnb {
  display: grid; grid-template-columns: minmax(220px, 1.4fr) repeat(3, minmax(130px, .8fr)) auto;
  gap: 12px; align-items: end; background: #fff; border: 1px solid var(--by-line);
  border-radius: var(--by-r); padding: 18px; box-shadow: var(--by-shadow); margin-bottom: 24px;
}
.by-filter-group { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.by-filter-group label { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--by-muted); }
.by-filter-group input, .by-filter-group select {
  height: 50px; width: 100%; padding: 0 14px; border: 1.5px solid var(--by-line); border-radius: var(--by-r-sm);
  font-family: inherit; font-size: 15px; color: var(--by-text); background: #fff; transition: border-color var(--by-ease), box-shadow var(--by-ease);
}
.by-filter-group input:focus, .by-filter-group select:focus { outline: none; border-color: var(--by-primary); box-shadow: 0 0 0 3px rgba(33,60,133,.1); }
.by-price-filter-inline { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.by-filter-actions { display: flex; gap: 10px; align-items: end; }
.by-filter-actions .by-btn { height: 50px; }

/* ── Results meta ─────────────────────────────────────────────── */
.by-results-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
#by-results-count { font-size: 15px; color: var(--by-muted); font-weight: 500; }
.by-view-toggle { display: flex; gap: 8px; }
.by-view-btn {
  width: 42px; height: 42px; border: 1.5px solid var(--by-line); border-radius: var(--by-r-sm);
  background: #fff; color: var(--by-primary); font-size: 17px; cursor: pointer; transition: all var(--by-ease);
}
.by-view-btn.active, .by-view-btn:hover { background: var(--by-primary); color: #fff; border-color: var(--by-primary); }

/* ── Listings grid ────────────────────────────────────────────── */
.by-listings-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.by-listings-grid.list-view { grid-template-columns: 1fr; gap: 16px; }
.by-listings-grid.list-view .by-listing-card { flex-direction: row; }
.by-listings-grid.list-view .by-card-image-wrap { width: 280px; aspect-ratio: 4/3; flex-shrink: 0; border-radius: var(--by-r) 0 0 var(--by-r); }
.by-listings-grid.list-view .by-card-body { padding: 22px 26px; justify-content: center; }

.by-listing-card {
  background: #fff; border: 1px solid var(--by-line); border-radius: var(--by-r);
  overflow: hidden; box-shadow: var(--by-shadow); display: flex; flex-direction: column;
  transition: transform var(--by-ease), box-shadow var(--by-ease);
}
.by-listing-card:hover { transform: translateY(-4px); box-shadow: var(--by-shadow-lg); }
.by-card-image-wrap { position: relative; display: block; aspect-ratio: 4/3; overflow: hidden; background: var(--by-bg-soft); }
.by-card-img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease, opacity var(--by-ease); }
.by-card-img-hover { position: absolute; inset: 0; opacity: 0; }
.by-card-image-wrap:hover .by-card-img-primary { transform: scale(1.05); }
.by-card-image-wrap:hover .by-card-img-hover { opacity: 1; }
.by-card-img-placeholder { width: 100%; height: 100%; background: linear-gradient(135deg, #dce3f0, #c5d0e8); }
.by-card-badge { position: absolute; top: 12px; right: 12px; background: #fff; color: var(--by-ink); font-size: 13px; font-weight: 700; padding: 5px 11px; border-radius: 999px; box-shadow: 0 2px 8px rgba(0,0,0,.14); }
.by-card-tag { position: absolute; bottom: 12px; left: 12px; background: var(--by-primary); color: #fff; font-size: 11px; font-weight: 700; padding: 5px 11px; border-radius: 999px; letter-spacing: .02em; }

.by-card-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.by-card-location { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--by-muted); }
.by-card-title { font-size: 17px; font-weight: 700; margin: 0; line-height: 1.3; letter-spacing: -.01em; }
.by-card-title a { color: var(--by-ink); transition: color var(--by-ease); }
.by-card-title a:hover { color: var(--by-primary); }
.by-card-meta { display: flex; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--by-muted); margin-top: 2px; }
.by-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--by-line); }
.by-card-price strong { font-size: 18px; color: var(--by-ink); font-weight: 800; }
.by-card-price-unit { font-size: 13px; color: var(--by-muted); }
.by-price-on-request { font-size: 13px; font-style: italic; color: var(--by-muted); }
.by-no-results { padding: 48px; text-align: center; color: var(--by-muted); font-size: 15px; }

/* ── Back link ────────────────────────────────────────────────── */
.by-back-link { display: inline-flex; align-items: center; gap: 7px; color: var(--by-muted); font-size: 14px; font-weight: 600; margin-bottom: 22px; transition: color var(--by-ease); }
.by-back-link:hover { color: var(--by-primary); }

/* ── Gallery ──────────────────────────────────────────────────── */
.by-gallery-layout {
  display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(300px, .8fr);
  grid-template-rows: minmax(240px, 300px) minmax(240px, 300px); gap: 8px;
  border-radius: var(--by-r-lg); overflow: hidden; margin-bottom: 28px; box-shadow: var(--by-shadow);
}
.by-gallery-hero { grid-row: 1 / 3; position: relative; overflow: hidden; cursor: pointer; }
.by-gallery-hero-img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.by-gallery-hero:hover .by-gallery-hero-img { transform: scale(1.03); }
.by-gallery-side { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 8px; }
.by-gallery-side-cell { position: relative; overflow: hidden; cursor: pointer; }
.by-gallery-side-img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.by-gallery-side-cell:hover .by-gallery-side-img { transform: scale(1.05); }
.by-gallery-more-btn {
  position: absolute; bottom: 16px; right: 16px; display: flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,.96); border: 1px solid rgba(15,23,42,.08); border-radius: var(--by-r-sm);
  padding: 10px 15px; font-size: 13px; font-weight: 700; color: var(--by-ink); cursor: pointer;
  box-shadow: 0 6px 18px rgba(15,23,42,.16); backdrop-filter: blur(6px); transition: all var(--by-ease);
}
.by-gallery-more-btn:hover { background: var(--by-primary); color: #fff; }
.by-gallery-more-standalone { position: static; margin-top: 10px; }

/* ── Lightbox ─────────────────────────────────────────────────── */
.by-lightbox { position: fixed; inset: 0; z-index: 99999; background: rgba(0,0,0,.97); display: flex; flex-direction: column; }
.by-lightbox-inner { display: flex; flex-direction: column; height: 100%; }
.by-lightbox-header { display: flex; justify-content: space-between; align-items: center; padding: 16px 24px; color: rgba(255,255,255,.7); font-size: 14px; }
.by-lightbox-close { background: rgba(255,255,255,.14); border: none; color: #fff; padding: 9px 16px; border-radius: var(--by-r-sm); cursor: pointer; font-size: 14px; font-weight: 600; }
.by-lightbox-close:hover { background: rgba(255,255,255,.24); }
.by-lightbox-main { flex: 1; display: flex; align-items: center; justify-content: center; position: relative; min-height: 0; padding: 20px 80px; }
.by-lb-full { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; }
.by-lb-arrow { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,.16); border: none; color: #fff; border-radius: 50%; width: 52px; height: 52px; font-size: 28px; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.by-lb-arrow:hover { background: rgba(255,255,255,.3); }
.by-lb-prev { left: 16px; } .by-lb-next { right: 16px; }
.by-lightbox-counter { text-align: center; color: rgba(255,255,255,.6); font-size: 13px; padding: 8px; }
.by-lightbox-strip { display: flex; gap: 6px; padding: 12px 20px; overflow-x: auto; }
.by-lb-thumb { width: 80px; height: 56px; object-fit: cover; border-radius: 5px; cursor: pointer; flex-shrink: 0; opacity: .55; border: 2px solid transparent; transition: all var(--by-ease); }
.by-lb-thumb.active, .by-lb-thumb:hover { opacity: 1; border-color: #fff; }

/* ── Detail layout ────────────────────────────────────────────── */
.by-detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 392px; gap: 56px; align-items: start; }
.by-detail-main { min-width: 0; }
.by-detail-header { padding-bottom: 4px; }
.by-detail-location { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--by-muted); margin-bottom: 10px; }
.by-detail-title { font-size: clamp(28px, 3.2vw, 44px); font-weight: 800; color: var(--by-ink); margin: 0 0 16px; line-height: 1.1; letter-spacing: -.025em; }
.by-detail-stats { display: flex; flex-wrap: wrap; gap: 18px; font-size: 15px; color: var(--by-muted); padding-bottom: 28px; border-bottom: 1px solid var(--by-line); }
.by-detail-stats span { display: flex; align-items: center; gap: 5px; }
.by-detail-stats strong { color: var(--by-ink); }
.by-detail-section { padding: 30px 0; border-bottom: 1px solid var(--by-line); }
.by-detail-section h2 { font-size: 20px; font-weight: 700; color: var(--by-ink); margin: 0 0 18px; letter-spacing: -.01em; }

/* ── Description ──────────────────────────────────────────────── */
.by-description { font-size: 16px; line-height: 1.8; color: #374151; overflow: hidden; position: relative; }
.by-description.collapsed { max-height: 150px; }
.by-description.expanded { max-height: none; }
.by-desc-fade { position: absolute; bottom: 0; left: 0; right: 0; height: 56px; background: linear-gradient(transparent, #fff); pointer-events: none; }
.by-description.expanded .by-desc-fade { display: none; }
.by-read-more { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; padding: 11px 18px; border-radius: 999px; background: var(--by-primary); color: #fff; border: none; font-size: 14px; font-weight: 700; cursor: pointer; transition: background var(--by-ease); }
.by-read-more:hover { background: var(--by-primary-dark); }

/* ── Amenities ────────────────────────────────────────────────── */
.by-amenities-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 16px; margin-bottom: 20px; }
.by-amenity-item { display: flex; align-items: center; gap: 12px; font-size: 15px; color: var(--by-text); }
.by-amenity-icon { font-size: 20px; width: 26px; text-align: center; flex-shrink: 0; }

/* ── House rules ──────────────────────────────────────────────── */
.by-rule-row { display: flex; align-items: flex-start; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--by-line); }
.by-rule-row:last-child { border-bottom: none; }
.by-rule-icon { font-size: 20px; width: 28px; text-align: center; flex-shrink: 0; margin-top: 1px; }
.by-rule-label { font-size: 13px; color: var(--by-muted); font-weight: 600; margin-bottom: 2px; }
.by-rule-val { font-size: 15px; color: var(--by-ink); font-weight: 600; }
.by-rule-sub { font-size: 13px; color: var(--by-muted); margin-top: 4px; line-height: 1.55; }

/* ── Cancellation policy ──────────────────────────────────────── */
.by-cancel-box { background: var(--by-bg-soft); border-radius: var(--by-r); padding: 22px 24px; border: 1px solid var(--by-line); }
.by-cancel-badge { display: inline-block; background: var(--by-primary); color: #fff; font-size: 12px; font-weight: 700; padding: 5px 13px; border-radius: 999px; margin-bottom: 12px; }
.by-cancel-text { font-size: 14px; color: var(--by-text); line-height: 1.7; }
.by-cancel-text strong { color: var(--by-primary); }

/* ── Booking panel (sticky, no overlap hack) ──────────────────── */
.by-booking-panel { position: sticky; top: 32px; }
.by-panel-inner { background: #fff; border: 1px solid var(--by-line); border-radius: var(--by-r-lg); padding: 28px; box-shadow: var(--by-shadow-lg); }
.by-panel-price { display: flex; align-items: baseline; gap: 6px; margin-bottom: 20px; }
.by-price-amount { font-size: 30px; font-weight: 800; color: var(--by-ink); letter-spacing: -.025em; }
.by-price-unit { font-size: 16px; font-weight: 400; color: var(--by-muted); }

/* ── Calendar widget ──────────────────────────────────────────── */
.by-cal-widget { margin-bottom: 16px; }
.by-cal-labels { display: flex; align-items: stretch; border: 1.5px solid var(--by-line); border-radius: var(--by-r); overflow: hidden; margin-bottom: 12px; cursor: pointer; }
.by-cal-label-field { flex: 1; padding: 14px 16px; transition: background var(--by-ease); }
.by-cal-label-field.active { background: var(--by-primary); }
.by-cal-label-field.active .by-cal-label-title, .by-cal-label-field.active .by-cal-label-val { color: #fff; }
.by-cal-label-title { display: block; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--by-muted); margin-bottom: 4px; }
.by-cal-label-val { display: block; font-size: 16px; font-weight: 700; color: var(--by-ink); }
.by-cal-arrow { display: flex; align-items: center; padding: 0 14px; color: var(--by-muted); font-size: 18px; background: var(--by-bg-soft); border-left: 1px solid var(--by-line); border-right: 1px solid var(--by-line); }
.by-cal-body { border: 1.5px solid var(--by-line); border-radius: var(--by-r); padding: 16px; }
.by-cal-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.by-cal-nav-btn { width: 40px; height: 40px; border: 1.5px solid var(--by-line); border-radius: 12px; background: #fff; font-size: 21px; cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--by-ink); transition: all var(--by-ease); }
.by-cal-nav-btn:hover { background: var(--by-primary); border-color: var(--by-primary); color: #fff; }
.by-cal-month-title { font-size: 15px; font-weight: 700; color: var(--by-ink); }
.by-cal-days-header { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin-bottom: 6px; }
.by-cal-days-header span { text-align: center; font-size: 10px; font-weight: 700; color: var(--by-muted); text-transform: uppercase; padding: 3px 0; }
.by-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.by-cal-cell { height: 42px; display: flex; align-items: center; justify-content: center; border-radius: 12px; position: relative; }
.by-cal-cell[data-date] { cursor: pointer; transition: background var(--by-ease), transform var(--by-ease); }
.by-cal-cell[data-date]:hover { background: var(--by-primary-soft); transform: translateY(-1px); }
.by-cal-blocked { opacity: .45; background: var(--by-bg-soft); cursor: not-allowed; }
.by-cal-blocked .by-cal-day { text-decoration: line-through; }
.by-cal-checkout-only { opacity: 1; background: #fff; border: 1px dashed #c7d2fe; }
.by-cal-checkout-only .by-cal-day { text-decoration: none; }
.by-cal-today .by-cal-day { font-weight: 800; color: var(--by-primary); }
.by-cal-selected-in, .by-cal-selected-out { background: linear-gradient(135deg, var(--by-primary), #2f56ba); box-shadow: 0 8px 20px rgba(33,60,133,.25); }
.by-cal-selected-in .by-cal-day, .by-cal-selected-out .by-cal-day { color: #fff; font-weight: 700; }
.by-cal-in-range { background: rgba(33,60,133,.1); border-radius: 0; }
.by-cal-day { font-size: 15px; font-weight: 600; color: var(--by-ink); line-height: 1; }

/* ── Guests ───────────────────────────────────────────────────── */
.by-guests-field { border: 1.5px solid var(--by-line); border-radius: var(--by-r); padding: 16px 18px; margin-bottom: 16px; }
.by-guests-field > label { font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--by-muted); display: block; margin-bottom: 10px; }
.by-guests-control { display: flex; align-items: center; gap: 14px; }
.by-guests-btn { width: 46px; height: 46px; border-radius: 50%; border: 1.5px solid var(--by-line); background: #fff; font-size: 26px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--by-ink); flex-shrink: 0; transition: all var(--by-ease); }
.by-guests-btn:hover:not(:disabled) { border-color: var(--by-primary); background: var(--by-primary); color: #fff; }
.by-guests-btn:disabled { opacity: .35; cursor: not-allowed; }
.by-guests-count-wrap { flex: 1; text-align: center; display: flex; align-items: baseline; justify-content: center; gap: 6px; }
#by-guests-count { font-size: 22px; font-weight: 700; color: var(--by-ink); }
.by-guests-label { font-size: 15px; color: var(--by-muted); }
.by-guests-field small { font-size: 12px; color: var(--by-muted); margin-top: 8px; display: block; }

/* ── Availability message ─────────────────────────────────────── */
.by-avail-msg { padding: 13px 15px; border-radius: var(--by-r-sm); font-size: 14px; font-weight: 600; margin: 14px 0; }
.by-avail-msg.success { background: var(--by-success-bg); color: #15803d; border: 1px solid #bbf7d0; }
.by-avail-msg.error { background: var(--by-error-bg); color: var(--by-error); border: 1px solid #fca5a5; }

/* ── Price breakdown ──────────────────────────────────────────── */
.by-price-breakdown { background: var(--by-bg-soft); border-radius: var(--by-r); padding: 16px 18px; margin: 14px 0; font-size: 14px; border: 1px solid var(--by-line); }
.by-breakdown-row { display: flex; justify-content: space-between; align-items: center; padding: 6px 0; color: var(--by-text); }
.by-breakdown-row.total { border-top: 1px solid var(--by-line); margin-top: 8px; padding-top: 12px; font-weight: 800; font-size: 16px; color: var(--by-ink); }

/* ── Upsells ──────────────────────────────────────────────────── */
.by-upsells { margin: 16px 0; }
.by-upsells-title { font-size: 12px; font-weight: 700; color: var(--by-ink); margin: 0 0 10px; text-transform: uppercase; letter-spacing: .06em; }
.by-upsell-item { display: flex; align-items: flex-start; gap: 12px; padding: 14px 15px; border: 1.5px solid var(--by-line); border-radius: var(--by-r); margin-bottom: 8px; cursor: pointer; transition: all var(--by-ease); }
.by-upsell-item:hover { border-color: var(--by-primary); background: var(--by-primary-soft); }
.by-upsell-item.selected { border-color: var(--by-primary); background: var(--by-primary-soft); }
.by-upsell-item input[type=checkbox] { margin-top: 2px; accent-color: var(--by-primary); width: 18px; height: 18px; }
.by-upsell-info { flex: 1; min-width: 0; }
.by-upsell-name { font-size: 14px; font-weight: 600; color: var(--by-ink); }
.by-upsell-desc { font-size: 12px; color: var(--by-muted); margin-top: 2px; }
.by-upsell-price { font-size: 14px; font-weight: 700; color: var(--by-primary); white-space: nowrap; flex-shrink: 0; }
.by-upsell-price small { font-weight: 400; color: var(--by-muted); font-size: 11px; }

#by-check-availability, #by-reserve-btn, .by-submit-btn { min-height: 56px; font-size: 16px; }
#by-reserve-btn { margin-top: 14px; }
.by-no-charge-note { text-align: center; font-size: 12px; color: var(--by-muted); margin: 12px 0 0; line-height: 1.5; }

/* ── Modals ───────────────────────────────────────────────────── */
.by-modal { position: fixed; inset: 0; z-index: 9999; background: rgba(15,23,42,.55); backdrop-filter: blur(6px); display: flex; align-items: center; justify-content: center; padding: 20px; animation: byFade .2s ease; }
@keyframes byFade { from { opacity: 0; } to { opacity: 1; } }
.by-modal-inner { background: #fff; border-radius: var(--by-r-lg); padding: 40px; max-width: 680px; width: 100%; max-height: 92vh; overflow-y: auto; position: relative; box-shadow: var(--by-shadow-lg); animation: bySlide .26s ease; }
@keyframes bySlide { from { transform: translateY(16px); opacity: 0; } to { transform: none; opacity: 1; } }
.by-modal-close { position: absolute; top: 16px; right: 16px; width: 42px; height: 42px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; background: rgba(255,255,255,.96); border: 1px solid var(--by-line); box-shadow: 0 6px 18px rgba(15,23,42,.1); font-size: 18px; cursor: pointer; color: var(--by-ink); z-index: 9; transition: background var(--by-ease); }
.by-modal-close:hover { background: var(--by-bg-soft); }

/* ── Checkout modal ───────────────────────────────────────────── */
.by-checkout-inner { max-width: 1080px; padding: 0; overflow: hidden; }
.by-checkout-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; min-height: 540px; }
.by-checkout-form { padding: 44px; overflow-y: auto; max-height: 92vh; }
.by-checkout-form h2 { font-size: 30px; font-weight: 800; margin: 0 0 6px; color: var(--by-ink); letter-spacing: -.025em; }
.by-checkout-sub { font-size: 15px; color: var(--by-muted); margin: 0 0 28px; line-height: 1.6; }
.by-checkout-form h3 { font-size: 16px; font-weight: 700; margin: 26px 0 16px; color: var(--by-ink); border-top: 1px solid var(--by-line); padding-top: 24px; }
.by-checkout-form h3:first-of-type { margin-top: 0; border-top: none; padding-top: 0; }
.by-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.by-form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.by-form-group label { font-size: 13px; font-weight: 600; color: var(--by-ink); }
.req { color: var(--by-error); margin-left: 2px; }
.by-optional { font-size: 12px; color: var(--by-muted); font-weight: 400; }
.by-form-group input, .by-form-group textarea { padding: 12px 14px; border: 1.5px solid var(--by-line); border-radius: var(--by-r-sm); font-family: inherit; font-size: 15px; color: var(--by-text); width: 100%; transition: border-color var(--by-ease), box-shadow var(--by-ease); }
.by-form-group input:focus, .by-form-group textarea:focus { outline: none; border-color: var(--by-primary); box-shadow: 0 0 0 3px rgba(33,60,133,.1); }

/* ── Payment element ──────────────────────────────────────────── */
.by-payment-element { min-height: 44px; }
.by-payment-loading { display: flex; align-items: center; gap: 10px; padding: 16px; color: var(--by-muted); font-size: 14px; }
.by-payment-help { margin-top: 10px; font-size: 13px; color: var(--by-muted); line-height: 1.5; }
.by-payment-error { margin-top: 10px; font-size: 13px; color: var(--by-error); }

/* ── Cancellation summary + terms ─────────────────────────────── */
.by-cancel-summary { background: var(--by-primary-soft); border-radius: var(--by-r); padding: 16px 18px; margin: 18px 0; border: 1px solid #c7d3f5; }
.by-cancel-summary h4 { font-size: 14px; font-weight: 700; margin: 0 0 6px; color: var(--by-primary); }
.by-cancel-summary p { font-size: 13px; color: var(--by-text); margin: 0; line-height: 1.6; }
.by-terms-check { margin: 16px 0 20px; }
.by-checkbox-label { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: 13px; color: var(--by-muted); line-height: 1.5; }
.by-checkbox-label input { margin-top: 2px; accent-color: var(--by-primary); flex-shrink: 0; width: 18px; height: 18px; }
.by-checkbox-label a { color: var(--by-primary); text-decoration: underline; }
.by-checkout-error { background: var(--by-error-bg); border: 1px solid #fca5a5; color: var(--by-error); border-radius: var(--by-r-sm); padding: 13px 15px; font-size: 14px; margin-bottom: 16px; }
.by-submit-btn { padding: 15px; }
.by-secure-note { text-align: center; font-size: 12px; color: var(--by-muted); margin-top: 12px; }

/* ── Checkout summary sidebar ─────────────────────────────────── */
.by-checkout-summary { background: linear-gradient(180deg, #f8faff, #eef2ff); border-left: 1px solid var(--by-line); padding: 32px 28px; }
.by-summary-card { display: flex; flex-direction: column; gap: 18px; }
.by-summary-media img { width: 100%; aspect-ratio: 16/11; object-fit: cover; border-radius: var(--by-r); box-shadow: 0 10px 28px rgba(15,23,42,.12); }
.by-summary-content h4 { font-size: 16px; line-height: 1.35; margin: 0; color: var(--by-ink); }
.by-summary-lines { margin-top: 14px; padding-top: 14px; border-top: 1px solid rgba(148,163,184,.28); display: flex; flex-direction: column; gap: 10px; }
.by-summary-line { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.by-summary-line span { color: var(--by-muted); }
.by-summary-line strong { color: var(--by-ink); text-align: right; font-weight: 600; }
.by-summary-extras { margin-top: 18px; padding-top: 16px; border-top: 1px solid rgba(148,163,184,.28); font-size: 13px; color: var(--by-text); }
.by-summary-extras strong { display: block; margin-bottom: 8px; font-size: 12px; letter-spacing: .07em; text-transform: uppercase; color: var(--by-muted); }
.by-summary-extra + .by-summary-extra { margin-top: 6px; }
.by-summary-total { margin-top: 20px; padding-top: 18px; border-top: 2px solid rgba(33,60,133,.18); display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.by-summary-total span { font-size: 14px; color: var(--by-muted); font-weight: 600; }
.by-summary-total strong { font-size: 27px; line-height: 1; letter-spacing: -.025em; color: var(--by-ink); }
.by-summary-note { margin: 12px 0 0; font-size: 13px; line-height: 1.6; color: var(--by-muted); }

/* ── Success modal ────────────────────────────────────────────── */
.by-success-inner { max-width: 560px; text-align: center; padding: 48px 40px; }
.by-success-icon { width: 68px; height: 68px; background: var(--by-success); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 32px; margin: 0 auto 24px; }
.by-success-inner h2 { font-size: 27px; font-weight: 800; margin-bottom: 10px; letter-spacing: -.02em; }
.by-success-msg { font-size: 15px; color: var(--by-muted); line-height: 1.6; margin-bottom: 28px; }
.by-success-next { background: var(--by-bg-soft); border-radius: var(--by-r); padding: 22px; margin-bottom: 24px; text-align: left; }
.by-success-next h4 { font-size: 14px; font-weight: 700; margin: 0 0 14px; color: var(--by-ink); }
.by-success-steps { display: flex; flex-direction: column; gap: 12px; }
.by-success-step { display: flex; align-items: flex-start; gap: 12px; }
.by-success-step span { width: 26px; height: 26px; background: var(--by-primary); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; flex-shrink: 0; }
.by-success-step p { font-size: 14px; color: var(--by-text); margin: 0; line-height: 1.5; padding-top: 3px; }
.by-success-detail { text-align: left; background: var(--by-bg-soft); border: 1px solid var(--by-line); border-radius: var(--by-r); padding: 18px 20px; margin: 4px 0 18px; }
.by-sd-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: 14px; color: var(--by-muted); padding: 4px 0; }
.by-sd-row strong { color: var(--by-ink); font-weight: 700; text-align: right; }
.by-sd-dates { display: flex; align-items: center; gap: 14px; margin: 12px 0; padding: 12px 0; border-top: 1px solid var(--by-line); border-bottom: 1px solid var(--by-line); }
.by-sd-date { flex: 1; }
.by-sd-date span { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--by-muted); margin-bottom: 2px; }
.by-sd-date strong { font-size: 15px; color: var(--by-ink); }
.by-sd-arrow { color: var(--by-primary); font-size: 18px; font-weight: 700; }
.by-success-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 22px; }
.by-success-actions .by-btn { flex: 1; min-width: 180px; }
.by-success-hero { margin: 0 0 20px; border-radius: var(--by-r); overflow: hidden; }
.by-success-hero img { width: 100%; height: 180px; object-fit: cover; display: block; }
.by-success-welcome { text-align: left; font-size: 15px; line-height: 1.65; color: var(--by-text); margin-bottom: 24px; }
.by-success-welcome p { margin: 0 0 10px; }
.by-success-cph { margin-bottom: 24px; text-align: left; }
.by-success-cph h4 { font-size: 14px; font-weight: 700; margin: 0 0 12px; color: var(--by-ink); }
.by-cph-links { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.by-cph-link { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border: 1.5px solid var(--by-line); border-radius: var(--by-r-sm); font-size: 13px; font-weight: 600; color: var(--by-text); background: #fff; transition: all var(--by-ease); }
.by-cph-link:hover { border-color: var(--by-primary); background: var(--by-primary-soft); color: var(--by-primary); }

/* ── States ───────────────────────────────────────────────────── */
.by-error { color: var(--by-error); font-size: 14px; padding: 16px; background: var(--by-error-bg); border-radius: var(--by-r-sm); }
.by-empty { color: var(--by-muted); font-size: 15px; padding: 48px; text-align: center; }
.by-loading { display: inline-block; width: 16px; height: 16px; border: 2.5px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: bySpin .7s linear infinite; vertical-align: middle; }
.by-loading-dark { border: 2.5px solid rgba(33,60,133,.25); border-top-color: var(--by-primary); }
@keyframes bySpin { to { transform: rotate(360deg); } }

/* ── v3.5 polish: stats, house-rules grid, toggle, filters, gallery ── */
.by-detail-stats .by-stat { display: inline-flex; align-items: center; gap: 6px; }
.by-stat-ic { font-size: 16px; line-height: 1; }

.by-rules-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 28px; margin-top: 4px; }
.by-rule { display: flex; align-items: flex-start; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--by-line); }
.by-rule-ic { font-size: 19px; width: 24px; text-align: center; flex-shrink: 0; line-height: 1.3; }
.by-rule-k { font-size: 12px; color: var(--by-muted); text-transform: uppercase; letter-spacing: .04em; }
.by-rule-v { font-size: 15px; color: var(--by-ink); font-weight: 600; margin-top: 1px; }
.by-rules-extra { margin: 18px 0 0; padding-left: 20px; color: var(--by-text); font-size: 14px; line-height: 1.7; }
@media (max-width: 600px) { .by-rules-grid { grid-template-columns: 1fr; } }

/* View toggle — perfectly centered icons */
.by-view-btn { display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.by-view-btn svg { display: block; }

/* Filter bar — cleaner, airier, modern */
.by-filters-airbnb { border-radius: 18px; padding: 16px 18px; gap: 14px; box-shadow: 0 4px 20px rgba(15,23,42,.05); border-color: var(--by-line); }
.by-filters-airbnb input, .by-filters-airbnb select { border-radius: 12px; border-color: var(--by-line); transition: border-color var(--by-ease), box-shadow var(--by-ease); }
.by-filters-airbnb input:focus, .by-filters-airbnb select:focus { border-color: var(--by-primary); box-shadow: 0 0 0 3px rgba(33,60,133,.1); outline: none; }
.by-filters-airbnb .by-btn { border-radius: 12px; }

/* Detail gallery — taller, edge-to-edge, modern; side fills the hero height */
.by-gallery-layout { grid-template-rows: minmax(280px, 340px) minmax(280px, 340px); gap: 8px; border-radius: 20px; }
.by-gallery-more-btn { border-radius: 12px; font-weight: 700; padding: 11px 16px; }
.by-gallery-side { grid-row: 1 / 3; height: 100%; }
.by-gallery-side-6 { grid-template-rows: repeat(3, 1fr); }
.by-gallery-side-4 { grid-template-rows: 1fr 1fr; }
.by-gallery-side-cell { min-height: 0; }

/* ── v3.6 search: chips, dates, map ───────────────────────────── */
.by-amenity-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: -8px 0 20px; }
.by-chip { border: 1.5px solid var(--by-line); background: #fff; color: var(--by-text); border-radius: 999px; padding: 8px 15px; font-size: 13px; font-weight: 600; cursor: pointer; transition: all var(--by-ease); }
.by-chip:hover { border-color: var(--by-primary); }
.by-chip.active { background: var(--by-primary); color: #fff; border-color: var(--by-primary); }
.by-search-msg { font-size: 14px; color: var(--by-muted); margin: 0 0 16px; padding: 11px 15px; background: var(--by-bg-soft); border: 1px solid var(--by-line); border-radius: var(--by-r-sm); }
.by-search-msg.error { color: var(--by-error); background: var(--by-error-bg); border-color: #fca5a5; }
.by-filters-airbnb input[type=date] { height: 50px; width: 100%; padding: 0 12px; border: 1.5px solid var(--by-line); border-radius: 12px; font-family: inherit; font-size: 14px; color: var(--by-text); background: #fff; }
.by-map { height: 600px; border-radius: var(--by-r); overflow: hidden; border: 1px solid var(--by-line); margin-bottom: 24px; position: relative; z-index: 0; }
.leaflet-container { font-family: var(--by-font); }
.leaflet-div-icon.by-map-pin { background: transparent !important; border: 0 !important; }
.by-map-price { display: inline-block; transform: translate(-50%, -130%); background: #fff; color: var(--by-ink); font-weight: 700; font-size: 13px; padding: 5px 11px; border-radius: 999px; box-shadow: 0 2px 10px rgba(0,0,0,.22); white-space: nowrap; border: 1px solid var(--by-line); cursor: pointer; }
.by-map-price:hover { background: var(--by-primary); color: #fff; border-color: var(--by-primary); z-index: 1000; }
.by-map-pop { width: 190px; }
.by-map-pop img { width: 100%; height: 112px; object-fit: cover; border-radius: 8px; margin-bottom: 8px; display: block; }
.by-map-pop a { color: var(--by-primary); font-weight: 600; text-decoration: none; }
@media (max-width: 760px) { .by-map { height: 460px; } }

/* Split list + map (Airbnb-style) */
.by-split .by-results-body { display: grid; grid-template-columns: 1.45fr 1fr; gap: 22px; align-items: start; }
.by-split #by-listings-grid { grid-template-columns: 1fr 1fr; gap: 18px; }
.by-split #by-map { display: block !important; position: sticky; top: 20px; height: calc(100vh - 140px); margin-bottom: 0; }
.by-listing-card.by-card-hl { outline: 2px solid var(--by-primary); outline-offset: 2px; transform: translateY(-2px); box-shadow: var(--by-shadow-lg); }
.by-map-pin.by-pin-active { z-index: 1000 !important; }
.by-map-pin.by-pin-active .by-map-price { background: var(--by-primary); color: #fff; border-color: var(--by-primary); }
@media (max-width: 1100px) { .by-split #by-listings-grid { grid-template-columns: 1fr; } }
@media (max-width: 960px) { .by-split .by-results-body { grid-template-columns: 1fr; } .by-split #by-map { position: relative; height: 420px; top: 0; } }

/* ── v3.7: photo tour, listing map, host ──────────────────────── */
.by-photos { position: fixed; inset: 0; z-index: 100000; background: #fff; }
.by-photos-bar { position: sticky; top: 0; display: flex; align-items: center; gap: 16px; height: 64px; padding: 0 22px; background: #fff; border-bottom: 1px solid var(--by-line); z-index: 2; }
.by-photos-close { width: 40px; height: 40px; border-radius: 50%; border: none; background: transparent; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; color: var(--by-ink); }
.by-photos-close:hover { background: var(--by-bg-soft); }
.by-photos-title { font-weight: 600; font-size: 15px; color: var(--by-ink); }
.by-photos-scroll { position: absolute; top: 64px; left: 0; right: 0; bottom: 0; overflow-y: auto; padding: 28px 16px 64px; }
.by-photos-grid { max-width: 920px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.by-photo { margin: 0; border-radius: 14px; overflow: hidden; background: var(--by-bg-soft); aspect-ratio: 3/2; }
.by-photo-full { grid-column: 1 / -1; aspect-ratio: 16/10; }
.by-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 640px) { .by-photos-grid { grid-template-columns: 1fr; } .by-photo, .by-photo-full { grid-column: 1 / -1; aspect-ratio: 16/11; } }

.by-where-sub { color: var(--by-muted); font-size: 15px; margin: -8px 0 14px; }
.by-listing-map { height: 380px; border-radius: var(--by-r); overflow: hidden; border: 1px solid var(--by-line); position: relative; z-index: 0; }
.by-where-note { font-size: 13px; color: var(--by-muted); margin-top: 12px; }

.by-host-card { display: flex; align-items: center; gap: 18px; background: var(--by-bg-soft); border: 1px solid var(--by-line); border-radius: var(--by-r); padding: 20px 22px; }
.by-host-avatar { width: 64px; height: 64px; border-radius: 50%; background: var(--by-primary); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 800; flex-shrink: 0; overflow: hidden; }
.by-host-avatar img { width: 100%; height: 100%; object-fit: cover; }
.by-host-name { font-size: 17px; font-weight: 700; color: var(--by-ink); }
.by-host-verified { font-size: 12px; font-weight: 600; color: var(--by-success); margin-left: 8px; }
.by-host-meta { font-size: 14px; color: var(--by-muted); margin-top: 3px; }
.by-host-contact { display: inline-block; margin-top: 10px; font-size: 14px; font-weight: 600; color: var(--by-primary); }

/* ── v4.0: coupon, reviews, similar stays ─────────────────────── */
.by-coupon-row { display: flex; gap: 10px; }
.by-coupon-row input { flex: 1; }
.by-coupon-row .by-btn { padding: 11px 20px; flex-shrink: 0; }
.by-coupon-msg { margin-top: 8px; font-size: 13px; font-weight: 600; }
.by-coupon-msg.ok { color: var(--by-success); }
.by-coupon-msg.err { color: var(--by-error); }
.by-summary-discount strong { color: var(--by-success) !important; }

.by-reviews-avg { font-size: 15px; font-weight: 600; color: var(--by-muted); margin-left: 8px; }
.by-reviews-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 32px; }
.by-review-head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.by-review-avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--by-primary); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 18px; flex-shrink: 0; }
.by-review-name { font-weight: 700; color: var(--by-ink); font-size: 15px; }
.by-review-meta { font-size: 13px; color: var(--by-muted); }
.by-review-text { font-size: 14px; line-height: 1.7; color: var(--by-text); margin: 0; }
@media (max-width: 700px) { .by-reviews-grid { grid-template-columns: 1fr; } }

.by-similar-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.by-similar-card { display: flex; flex-direction: column; border: 1px solid var(--by-line); border-radius: var(--by-r); overflow: hidden; background: #fff; text-decoration: none; transition: transform var(--by-ease), box-shadow var(--by-ease); }
.by-similar-card:hover { transform: translateY(-3px); box-shadow: var(--by-shadow-lg); }
.by-similar-img { display: block; aspect-ratio: 4/3; overflow: hidden; }
.by-similar-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.by-similar-body { padding: 13px 15px; display: flex; flex-direction: column; gap: 3px; }
.by-similar-body strong { font-size: 14px; color: var(--by-ink); line-height: 1.35; }
.by-similar-meta { font-size: 13px; color: var(--by-muted); }
@media (max-width: 700px) { .by-similar-grid { grid-template-columns: 1fr; } }

/* ── Responsive ───────────────────────────────────────────────── */
@media (max-width: 1100px) {
  .by-listings-grid { grid-template-columns: repeat(2, 1fr); }
  .by-filters-airbnb { grid-template-columns: 1fr 1fr; }
  .by-filter-actions { grid-column: 1 / -1; justify-content: flex-end; }
}
@media (max-width: 960px) {
  .by-detail-layout { grid-template-columns: 1fr; gap: 28px; }
  .by-booking-panel { position: static; }
  .by-gallery-layout { grid-template-columns: 1fr; grid-template-rows: 300px; }
  .by-gallery-side { display: none; }
}
@media (max-width: 760px) {
  .by-checkout-layout { grid-template-columns: 1fr; }
  .by-checkout-summary { display: none; }
  .by-checkout-form { max-height: 92vh; padding: 32px 24px; }
  .by-checkout-form h2 { font-size: 26px; }
  .by-form-row { grid-template-columns: 1fr; }
  .by-modal-inner { padding: 28px 20px; }
  .by-lightbox-main { padding: 10px 50px; }
  .by-lb-arrow { width: 40px; height: 40px; font-size: 22px; }
}
@media (max-width: 640px) {
  .by-listings-grid { grid-template-columns: 1fr; }
  .by-listings-grid.list-view .by-listing-card { flex-direction: column; }
  .by-listings-grid.list-view .by-card-image-wrap { width: 100%; border-radius: var(--by-r) var(--by-r) 0 0; }
  .by-filters-airbnb { grid-template-columns: 1fr; }
  .by-filter-actions { flex-direction: column; }
  .by-filter-actions .by-btn { width: 100%; }
  .by-cph-links { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════════════════════════
   v4.1: search bar, filters modal, active chips, map fab,
   calendar contrast, always-visible Book CTA, host-support footer
   ════════════════════════════════════════════════════════════════ */

/* ── Search bar ──────────────────────────────────────────────── */
.by-searchbar {
  display: grid; grid-template-columns: minmax(200px, 1.5fr) repeat(2, minmax(140px, .9fr)) minmax(120px, .8fr) auto minmax(150px, .8fr);
  gap: 10px; align-items: end; background: #fff; border: 1px solid var(--by-line);
  border-radius: 18px; padding: 14px 16px; box-shadow: 0 4px 20px rgba(15,23,42,.05); margin-bottom: 14px;
}
.by-searchbar-nosort { grid-template-columns: minmax(200px, 1.5fr) repeat(2, minmax(140px, .9fr)) minmax(120px, .8fr) auto; }
.by-sb-field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.by-sb-field label { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--by-muted); }
.by-sb-field input, .by-sb-field select {
  height: 48px; padding: 0 13px; border: 1.5px solid var(--by-line); border-radius: 12px;
  font-family: inherit; font-size: 14px; color: var(--by-text); background: #fff; width: 100%;
  transition: border-color var(--by-ease), box-shadow var(--by-ease);
}
.by-sb-field input:focus, .by-sb-field select:focus { outline: none; border-color: var(--by-primary); box-shadow: 0 0 0 3px rgba(33,60,133,.1); }
.by-sb-filters {
  height: 48px; align-self: end; display: inline-flex; align-items: center; gap: 8px;
  border: 1.5px solid var(--by-line); background: #fff; color: var(--by-ink); border-radius: 12px;
  padding: 0 18px; font-family: inherit; font-size: 14px; font-weight: 700; cursor: pointer; white-space: nowrap;
  transition: border-color var(--by-ease), color var(--by-ease);
}
.by-sb-filters:hover { border-color: var(--by-primary); color: var(--by-primary); }
.by-filter-count { background: var(--by-primary); color: #fff; min-width: 20px; height: 20px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; padding: 0 6px; }

/* ── Active filter chips (intuitive clearing) ────────────────── */
.by-active-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 18px; }
.by-af-chip {
  display: inline-flex; align-items: center; gap: 7px; background: var(--by-primary-soft); color: var(--by-primary);
  border: 1.5px solid rgba(33,60,133,.22); border-radius: 999px; padding: 7px 13px;
  font-family: inherit; font-size: 13px; font-weight: 600; cursor: pointer; transition: all var(--by-ease);
}
.by-af-chip span { font-size: 11px; opacity: .75; }
.by-af-chip:hover { background: var(--by-primary); color: #fff; }

/* ── Filters modal ───────────────────────────────────────────── */
.by-filter-modal { align-items: center; }
.by-filter-inner { max-width: 640px; width: 100%; padding: 0; display: flex; flex-direction: column; max-height: 88vh; overflow: hidden; }
.by-fm-head { display: flex; align-items: center; justify-content: center; position: relative; padding: 18px 24px; border-bottom: 1px solid var(--by-line); flex-shrink: 0; }
.by-fm-head h3 { margin: 0; font-size: 17px; font-weight: 800; color: var(--by-ink); }
.by-fm-close { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border-radius: 50%; border: none; background: transparent; font-size: 16px; cursor: pointer; color: var(--by-ink); display: inline-flex; align-items: center; justify-content: center; }
.by-fm-close:hover { background: var(--by-bg-soft); }
.by-fm-body { overflow-y: auto; padding: 4px 26px; flex: 1; min-height: 0; }
.by-fm-section { padding: 22px 0; border-bottom: 1px solid var(--by-line); }
.by-fm-section:last-child { border-bottom: none; }
.by-fm-section h4 { margin: 0 0 14px; font-size: 15px; font-weight: 700; color: var(--by-ink); }
.by-fm-sub { font-weight: 400; color: var(--by-muted); font-size: 13px; }
.by-fm-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.by-fm-foot { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 15px 24px; border-top: 1px solid var(--by-line); background: #fff; flex-shrink: 0; }
.by-fm-foot .by-btn { padding: 13px 26px; }

/* Segmented property type */
.by-fm-seg { display: flex; border: 1.5px solid var(--by-line); border-radius: 14px; overflow: hidden; }
.by-seg { flex: 1; padding: 13px 10px; background: #fff; border: none; border-right: 1px solid var(--by-line); font-family: inherit; font-size: 14px; font-weight: 600; color: var(--by-text); cursor: pointer; transition: background var(--by-ease), color var(--by-ease); }
.by-seg:last-child { border-right: none; }
.by-seg:hover { background: var(--by-bg-soft); }
.by-seg.active { background: var(--by-primary); color: #fff; }

/* Steppers */
.by-step-row { display: flex; align-items: center; justify-content: space-between; padding: 9px 0; }
.by-step-label { font-size: 15px; color: var(--by-text); }
.by-stepper { display: flex; align-items: center; gap: 14px; }
.by-step-btn { width: 36px; height: 36px; border-radius: 50%; border: 1.5px solid var(--by-line); background: #fff; font-size: 18px; line-height: 1; cursor: pointer; color: var(--by-ink); display: inline-flex; align-items: center; justify-content: center; transition: all var(--by-ease); }
.by-step-btn:hover { border-color: var(--by-primary); color: var(--by-primary); }
.by-step-val { min-width: 46px; text-align: center; font-size: 14px; font-weight: 600; color: var(--by-ink); }

/* Dual price slider */
.by-range-wrap { position: relative; height: 36px; margin: 6px 8px 2px; }
.by-range-track { position: absolute; top: 50%; left: 0; right: 0; height: 4px; transform: translateY(-50%); background: var(--by-line); border-radius: 999px; }
.by-range-fill { position: absolute; top: 0; bottom: 0; background: var(--by-primary); border-radius: 999px; }
.by-range-wrap input[type=range] { position: absolute; inset: 0; width: 100%; height: 36px; margin: 0; -webkit-appearance: none; appearance: none; background: transparent; pointer-events: none; }
.by-range-wrap input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; pointer-events: auto; width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 1.5px solid var(--by-line); box-shadow: 0 2px 8px rgba(15,23,42,.18); cursor: grab; }
.by-range-wrap input[type=range]::-moz-range-thumb { pointer-events: auto; width: 24px; height: 24px; border-radius: 50%; background: #fff; border: 1.5px solid var(--by-line); box-shadow: 0 2px 8px rgba(15,23,42,.18); cursor: grab; }
.by-range-values { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.by-range-box { border: 1.5px solid var(--by-line); border-radius: 12px; padding: 8px 14px; }
.by-range-box label { display: block; font-size: 11px; color: var(--by-muted); text-transform: uppercase; letter-spacing: .05em; }
.by-range-box input { border: none; outline: none; width: 100%; font-family: inherit; font-size: 15px; font-weight: 600; color: var(--by-ink); padding: 2px 0 0; background: transparent; }

/* ── Floating "Show map" pill ────────────────────────────────── */
.by-map-fab {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: 28px; z-index: 8500;
  display: inline-flex; align-items: center; gap: 8px; background: var(--by-ink); color: #fff;
  border: none; border-radius: 999px; padding: 13px 22px; font-family: var(--by-font);
  font-size: 14px; font-weight: 700; cursor: pointer; box-shadow: 0 10px 30px rgba(15,23,42,.35);
  transition: transform var(--by-ease), box-shadow var(--by-ease);
}
.by-map-fab:hover { transform: translateX(-50%) scale(1.05); box-shadow: 0 14px 36px rgba(15,23,42,.4); }

/* Google Maps price pill overlay */
.by-gpin { cursor: pointer; z-index: 1; }
.by-gpin.by-pin-active { z-index: 1000; }

/* ── Calendar: stronger available vs booked contrast ─────────── */
.by-cal-blocked { opacity: 1; background: repeating-linear-gradient(135deg, #f3f4f6, #f3f4f6 4px, #eceef2 4px, #eceef2 8px); cursor: not-allowed; }
.by-cal-blocked .by-cal-day { color: #b3bac6; text-decoration: line-through; font-weight: 500; }
.by-cal-cell[data-date] { background: #fff; box-shadow: inset 0 0 0 1px var(--by-line); }
.by-cal-cell[data-date]:hover { background: #fff; box-shadow: inset 0 0 0 2px var(--by-primary); transform: none; }
.by-cal-empty { background: transparent; box-shadow: none; }
/* Selection states must win over the white available-cell base above. */
.by-cal-cell[data-date].by-cal-selected-in, .by-cal-cell[data-date].by-cal-selected-out,
.by-cal-cell[data-date].by-cal-selected-in:hover, .by-cal-cell[data-date].by-cal-selected-out:hover {
  background: linear-gradient(135deg, var(--by-primary), #2f56ba); box-shadow: 0 8px 20px rgba(33,60,133,.25);
}
.by-cal-cell[data-date].by-cal-in-range, .by-cal-cell[data-date].by-cal-in-range:hover { background: rgba(33,60,133,.12); box-shadow: none; }
.by-cal-cell[data-date].by-cal-checkout-only { background: #fff; box-shadow: inset 0 0 0 1px #c7d2fe; border: none; }
.by-cal-cell[data-date].by-cal-checkout-only:hover { box-shadow: inset 0 0 0 2px var(--by-primary); }
.by-cal-cell.by-cal-selected-in, .by-cal-cell.by-cal-selected-out,
.by-cal-cell.by-cal-selected-in:hover, .by-cal-cell.by-cal-selected-out:hover {
  background: linear-gradient(135deg, var(--by-primary), #2f56ba); box-shadow: 0 8px 20px rgba(33,60,133,.25); cursor: pointer; opacity: 1;
}
.by-cal-cell.by-cal-selected-in .by-cal-day, .by-cal-cell.by-cal-selected-out .by-cal-day { color: #fff; font-weight: 700; text-decoration: none; }
.by-cal-cell.by-cal-in-range, .by-cal-cell.by-cal-in-range:hover { background: rgba(33,60,133,.12); box-shadow: none; }
.by-cal-cell.by-cal-in-range .by-cal-day { color: var(--by-ink); text-decoration: none; }

/* ── Booking panel: Book button always in view ───────────────── */
.by-booking-panel { position: sticky; top: 24px; max-height: calc(100vh - 48px); display: flex; }
.by-panel-inner { overflow-y: auto; display: flex; flex-direction: column; width: 100%; overscroll-behavior: contain; padding-bottom: 0; }
.by-panel-cta { position: sticky; bottom: 0; margin: 14px -28px 0; padding: 14px 28px 22px; background: #fff; border-top: 1px solid var(--by-line); z-index: 2; }
#by-book-btn { min-height: 56px; font-size: 16px; }
#by-book-total { font-weight: 700; }

/* Mobile fixed booking bar */
.by-mobile-bookbar {
  display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 9000;
  background: #fff; border-top: 1px solid var(--by-line);
  padding: 12px 18px calc(12px + env(safe-area-inset-bottom));
  align-items: center; justify-content: space-between; gap: 14px;
  box-shadow: 0 -8px 24px rgba(15,23,42,.08); font-family: var(--by-font);
}
.by-mbb-price strong { font-size: 18px; font-weight: 800; color: var(--by-ink); display: block; line-height: 1.2; }
.by-mbb-price span { font-size: 12px; color: var(--by-muted); }
#by-book-btn-m { min-height: 48px; padding: 12px 30px; flex-shrink: 0; }

/* ── Host-support footer + local gems ────────────────────────── */
.by-listings-wrap { padding-bottom: 96px; } /* clearance for the floating map pill */
.by-site-footer { margin-top: 56px; border-top: 1px solid var(--by-line); padding-top: 36px; }
.by-footer-gems { margin-bottom: 8px; }
.by-footer-heading { font-size: 22px; font-weight: 800; color: var(--by-ink); margin: 0 0 18px; letter-spacing: -.01em; }
.by-gems-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.by-gem-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--by-line); border-radius: var(--by-r); overflow: hidden; text-decoration: none; transition: transform var(--by-ease), box-shadow var(--by-ease); }
.by-gem-card:hover { transform: translateY(-3px); box-shadow: var(--by-shadow-lg); }
.by-gem-img { display: block; aspect-ratio: 16/10; overflow: hidden; background: var(--by-bg-soft); }
.by-gem-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.by-gem-card:hover .by-gem-img img { transform: scale(1.05); }
.by-gem-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 5px; }
.by-gem-tag { font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--by-primary); }
.by-gem-title { font-size: 15px; color: var(--by-ink); line-height: 1.35; }
.by-gem-text { font-size: 13px; color: var(--by-muted); line-height: 1.55; }
.by-gem-more { font-size: 13px; font-weight: 700; color: var(--by-primary); margin-top: 4px; }
.by-footer-support { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; background: var(--by-bg-soft); border: 1px solid var(--by-line); border-radius: var(--by-r-lg); padding: 24px 28px; margin: 28px 0 8px; }
.by-fs-left h3 { margin: 0 0 4px; font-size: 17px; font-weight: 800; color: var(--by-ink); }
.by-fs-left p { margin: 0; font-size: 14px; color: var(--by-muted); }
.by-fs-right { display: flex; gap: 10px; flex-wrap: wrap; }
.by-fs-contact { display: inline-flex; align-items: center; gap: 7px; background: #fff; border: 1.5px solid var(--by-line); border-radius: 12px; padding: 11px 17px; font-size: 14px; font-weight: 600; color: var(--by-ink); transition: all var(--by-ease); }
.by-fs-contact:hover { border-color: var(--by-primary); color: var(--by-primary); }

/* ── v4.1 responsive ─────────────────────────────────────────── */
@media (max-width: 1100px) {
  .by-searchbar { grid-template-columns: 1fr 1fr; }
  .by-sb-filters { align-self: stretch; height: auto; min-height: 48px; }
  .by-gems-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 960px) {
  .by-booking-panel { position: static; max-height: none; display: block; }
  .by-panel-inner { padding-bottom: 28px; }
  .by-panel-cta { position: static; margin: 14px 0 0; padding: 0; border-top: none; }
  .by-mobile-bookbar { display: flex; }
  .by-listing-detail { padding-bottom: 84px; }
}
@media (max-width: 640px) {
  .by-searchbar { grid-template-columns: 1fr; }
  .by-gems-grid { grid-template-columns: 1fr; }
  .by-footer-support { flex-direction: column; align-items: flex-start; }
  .by-filter-inner { max-height: 94vh; border-radius: 18px 18px 0 0; align-self: flex-end; }
  .by-filter-modal { align-items: flex-end; padding: 0; }
  .by-map-fab { bottom: 20px; }
}

/* ════════════════════════════════════════════════════════════════
   v4.1.1: similar-stay match badges, "what guests love" highlights,
   host avatar with logo
   ════════════════════════════════════════════════════════════════ */
.by-similar-badges { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; }
.by-similar-badge { font-size: 11px; font-weight: 600; color: var(--by-primary); background: var(--by-primary-soft); border: 1px solid rgba(33,60,133,.18); border-radius: 999px; padding: 3px 9px; line-height: 1.3; }

.by-highlights { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 28px; }
.by-highlights li { display: flex; align-items: flex-start; gap: 10px; font-size: 15px; color: var(--by-text); line-height: 1.5; }
.by-hl-check { flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; background: var(--by-success-bg); color: var(--by-success); display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 800; margin-top: 1px; }
@media (max-width: 600px) { .by-highlights { grid-template-columns: 1fr; } }

/* Host avatar shows the uploaded logo cleanly (white bg, contained, not cropped) */
.by-host-avatar.has-img { background: #fff; border: 1px solid var(--by-line); }
.by-host-avatar.has-img img { object-fit: contain; padding: 8px; }

/* ════════════════════════════════════════════════════════════════
   v4.1.2: UI polish — unified discrete close button, premium price
   slider, cleaner labels/spacing
   ════════════════════════════════════════════════════════════════ */

/* ── Unified close button: a simple, discrete cross (no oval/white box) ── */
.by-x {
  position: absolute; top: 14px; right: 14px; z-index: 12;
  width: 34px; height: 34px; padding: 0; margin: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent; border: 0; border-radius: 50%; box-shadow: none;
  color: var(--by-muted); cursor: pointer; line-height: 0;
  transition: color .15s ease, background .15s ease, transform .15s ease;
}
.by-x:hover { color: var(--by-ink); background: rgba(15,23,42,.06); }
.by-x:active { transform: scale(.92); }
.by-x:focus-visible { outline: 2px solid rgba(33,60,133,.45); outline-offset: 2px; }
.by-x svg { display: block; pointer-events: none; }
/* Override the old oval/white treatment wherever the class is combined */
.by-modal-close.by-x, .by-fm-close.by-x, .by-photos-close.by-x {
  background: transparent; border: 0; box-shadow: none; width: 34px; height: 34px;
}
.by-modal-close.by-x:hover, .by-fm-close.by-x:hover, .by-photos-close.by-x:hover { background: rgba(15,23,42,.06); }
/* Filter modal: cross to the right, title stays centred */
.by-fm-close.by-x { left: auto; right: 12px; top: 50%; transform: translateY(-50%); }
.by-fm-close.by-x:active { transform: translateY(-50%) scale(.92); }
/* Photo-tour close lives inside a flex bar, not absolutely positioned */
.by-photos-close.by-x { position: static; }

/* ── Premium price-range slider ──────────────────────────────────── */
.by-range-head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 20px; }
.by-range-head h4 { margin: 0; }
.by-range-wrap { position: relative; height: 40px; margin: 2px 12px 4px; }
.by-range-track { position: absolute; top: 50%; left: 0; right: 0; height: 5px; transform: translateY(-50%); background: var(--by-line); border-radius: 999px; }
.by-range-fill { position: absolute; top: 0; bottom: 0; background: linear-gradient(90deg, var(--by-primary), #2f56ba); border-radius: 999px; }
.by-range-wrap input[type=range] { position: absolute; inset: 0; width: 100%; height: 40px; margin: 0; -webkit-appearance: none; appearance: none; background: transparent; pointer-events: none; }
.by-range-wrap input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; pointer-events: auto; width: 28px; height: 28px; border-radius: 50%;
  background: #fff; border: 1.5px solid #d5dae6; box-shadow: 0 2px 7px rgba(15,23,42,.20);
  cursor: grab; transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}
.by-range-wrap input[type=range]::-webkit-slider-thumb:hover { border-color: var(--by-primary); box-shadow: 0 5px 14px rgba(33,60,133,.30); }
.by-range-wrap input[type=range]::-webkit-slider-thumb:active { cursor: grabbing; transform: scale(1.1); border-color: var(--by-primary); }
.by-range-wrap input[type=range]::-moz-range-thumb { pointer-events: auto; width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 1.5px solid #d5dae6; box-shadow: 0 2px 7px rgba(15,23,42,.20); cursor: grab; }
.by-range-wrap input[type=range]:focus-visible::-webkit-slider-thumb { outline: 2px solid rgba(33,60,133,.45); outline-offset: 2px; }

.by-range-values { display: flex; align-items: flex-end; gap: 12px; margin-top: 18px; }
.by-range-box { flex: 1; border: 0; padding: 0; border-radius: 0; }
.by-range-box label { display: block; font-size: 11px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--by-muted); margin-bottom: 7px; }
.by-range-field { display: flex; align-items: center; gap: 6px; border: 1.5px solid var(--by-line); border-radius: 12px; padding: 11px 14px; background: #fff; transition: border-color var(--by-ease), box-shadow var(--by-ease); }
.by-range-field:focus-within { border-color: var(--by-primary); box-shadow: 0 0 0 3px rgba(33,60,133,.1); }
.by-range-field input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-family: inherit; font-size: 16px; font-weight: 700; color: var(--by-ink); padding: 0; }
.by-range-field input::placeholder { color: #9aa3b2; font-weight: 600; }
.by-range-cur { font-size: 13px; font-weight: 600; color: var(--by-muted); flex-shrink: 0; }
.by-range-dash { color: var(--by-muted); font-size: 18px; padding-bottom: 12px; }

/* ── Segmented property-type control: a touch more premium ───────── */
.by-fm-seg { background: var(--by-bg-soft); border-color: transparent; padding: 4px; gap: 4px; border-radius: 14px; }
.by-seg { border-radius: 10px; border-right: 0; padding: 11px 12px; }
.by-seg.active { box-shadow: 0 2px 8px rgba(33,60,133,.22); }
