/* ============================
   Daz Saved Search Results
   Self-contained styling
   ============================ */

/* On saved-link pages, hide the theme banner title to avoid duplication */
body.daz-ssr .inner-banner #page-title {
  display: none;
}

/* Base widget */
.daz-ssr-widget {
  width: 100%;
}

/* Panel */
.daz-ssr-panel {
  margin-top: 10px;
  padding: 12px;
  border: 1px solid #eeeeee;
  border-radius: 8px;
  background: #ffffff;
}

/* Fields */
.daz-ssr-field {
  margin-bottom: 10px;
}

.daz-ssr-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 10px;
}

.daz-ssr-input {
  display: block;
  width: 100%;
  max-width: 100%;
  padding: 10px 10px;
  border: 1px solid #d7d7d7;
  border-radius: 6px;
  background: #ffffff;
  box-sizing: border-box;
}

/* Compact 2-column layout for full form (stacks on mobile) */
.daz-ssr-row {
  display: flex;
  gap: 10px;
}

.daz-ssr-col {
  flex: 1 1 0;
  min-width: 0;
}

@media (max-width: 520px) {
  .daz-ssr-row {
    flex-direction: column;
  }
}

/* GDPR consent */
.daz-ssr-consent-wrap {
  margin-top: 6px;
}

.daz-ssr-consent {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 12px;
  line-height: 1.35;
  font-weight: 500;
}

.daz-ssr-consent input[type="checkbox"] {
  margin-top: 2px;
}

.daz-ssr-consent-hint {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.35;
  opacity: 0.85;
}

/* Status */
.daz-ssr-status {
  display: block;
  margin: 8px 0;
  font-size: 13px;
  line-height: 1.35 !important;
  white-space: normal;
}

/* Primary button */
.daz-ssr-save-btn {
  display: inline-block;
  width: 100%;
  padding: 12px 14px;
  font-size: 13px;
  line-height: 1.2;
  border-radius: 6px;
  border: 1px solid #25d366;
  color: #25d366;
  background: #ffffff;
  cursor: pointer;
}

.daz-ssr-save-btn:focus {
  outline: none;
}

.daz-ssr-save-btn.daz-ssr-btn-saved {
  opacity: 0.75;
  cursor: default;
}

/* Share section */
.daz-ssr-share {
  margin-top: 12px;
}

.daz-ssr-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 8px;
}

.daz-ssr-actions > * {
  flex: 1 1 auto;
  text-align: center;
  margin: 0;
}

/* WhatsApp button */
a.daz-ssr-wa {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  background: #25d366;
  padding: 12px 14px;
  color: #ffffff;
  border-radius: 6px;
  border: 1px solid #000000;
  text-decoration: none;
  line-height: 1.2;
}

a.daz-ssr-wa:hover {
  text-decoration: none;
}

/* CTA mode tweaks */
.daz-ssr-mode-cta .daz-ssr-save-btn {
  width: 100%;
  padding: 12px 14px;
}

/* If the widget is inserted inside the MLS CTA area, give it consistent spacing */
.mls-prj-price.cn-area .daz-ssr-widget {
  margin-top: 10px;
}

/* Prevent theme styles from breaking layout */
.daz-ssr-widget label,
.daz-ssr-widget input,
.daz-ssr-widget button,
.daz-ssr-widget a {
  box-sizing: border-box;
}

/* Remove button on saved-link cards (server-side list) */
.daz-ssr-remove-row {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 12px 0 0 0;
  padding: 0;
}

.daz-ssr-remove-btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 260px;
  padding: 10px 12px;
  color: red;
  font-size: 13px;
  font-weight: 700;
  border-radius: 6px;
  border: 1px solid rgba(0, 0, 0, 0.25);
  background: #ffffff;
  cursor: pointer;
}

.daz-ssr-remove-btn:hover {
  background: rgba(255,255,255,1);
}

.daz-ssr-remove-btn:disabled {
  opacity: 0.6;
  cursor: default;
}

/* ============================
   A) Sticky Saved Bar
   ============================ */

.daz-ssr-savedbar {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 99999;
  pointer-events: auto;
  max-width: 700px;
  margin: 0 auto;
}

.daz-ssr-savedbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.12);
  background: #ffffff;
  box-shadow: 0 10px 22px rgba(0,0,0,0.12);
}

.daz-ssr-savedbar-text {
  font-size: 13px;
  line-height: 1.25;
}

.daz-ssr-savedbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.daz-ssr-savedbar-btn {
  padding: 8px 10px;
  font-size: 13px;
  border-radius: 8px;
  border: 1px solid rgba(0,0,0,0.18);
  background: #ffffff;
  cursor: pointer;
  white-space: nowrap;
}

.daz-ssr-savedbar-btn:hover {
  background: rgba(0,0,0,0.03);
}

.daz-ssr-savedbar-email {
  border-color: #25d366;
  color: #25d366;
}

.daz-ssr-savedbar-close {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(0,0,0,0.18);
  background: #ffffff;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.daz-ssr-savedbar-close:hover {
  background: rgba(0,0,0,0.03);
}

.daz-ssr-open-saved {
    line-height: 3;
    border: 1px solid #25d366;
    border-radius: 8px;
    color: #25d366;
    padding: 5px 20px;
}

/* Nav + opener highlight when there are saved properties */
.daz-ssr-has-saved {
  font-weight: 700;
  font-size: 18px !important;
  color: #25d366 !important;
  background: white;
  padding: 4px 10px !important;
  border-radius: 10px;}

/* If the CURRENT property is already saved, visually mark the Saved opener */
.daz-ssr-this-saved {
  text-decoration: underline;
}

.daz-ssr-empty {
    font-weight: bold;
    padding: 20px;
    border: 1px solid grey;
    box-shadow: 2px 2px 3px grey;
    background-color: rgba(0, 0, 0, 0.04);
}

.daz-ssr-empty h3 {
    text-align: center;
    color: #34b0d9;
}

@media (max-width: 520px) {
  .daz-ssr-savedbar-inner {
    flex-wrap: wrap;
    justify-content: flex-start;
  }
  .daz-ssr-savedbar-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
  }
}

/* ============================
   B) Drawer / Modal
   ============================ */

/* Ensure the HTML [hidden] attribute actually hides our UI, even if theme CSS overrides display */
.daz-ssr-savedbar[hidden],
.daz-ssr-drawer-overlay[hidden] {
  display: none !important;
}

.daz-ssr-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 100000;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  padding: 18px;
}

.daz-ssr-drawer {
  width: 100%;
  max-width: 720px;
  max-height: 88vh;
  overflow: hidden;
  border-radius: 14px;
  background: #ffffff;
  border: 1px solid rgba(0,0,0,0.15);
  box-shadow: 0 20px 50px rgba(0,0,0,0.25);
  display: flex;
  flex-direction: column;
}

.daz-ssr-drawer-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.daz-ssr-drawer-title {
  font-size: 15px;
  font-weight: 700;
}

.daz-ssr-drawer-close {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.18);
  background: #ffffff;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.daz-ssr-drawer-tabs {
  display: flex;
  gap: 8px;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  overflow-x: auto;
}

.daz-ssr-drawer-tab {
  padding: 8px 10px;
  font-size: 13px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.18);
  background: #ffffff;
  cursor: pointer;
  white-space: nowrap;
}

.daz-ssr-drawer-tab.is-active {
  border-color: #25d366;
  color: #25d366;
}

.daz-ssr-drawer-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 18px;
  padding: 0 6px;
  border-radius: 999px;
  margin-left: 6px;
  background: rgba(0,0,0,0.06);
  font-size: 12px;
}

.daz-ssr-drawer-body {
  padding: 12px 14px;
  overflow: auto;
  flex: 1 1 auto;
}

.daz-ssr-drawer-empty h4 {
  margin: 0 0 6px 0;
  font-size: 14px;
}

.daz-ssr-drawer-empty p {
  margin: 0;
  font-size: 13px;
  opacity: 0.85;
}

.daz-ssr-drawer-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.daz-ssr-drawer-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(0,0,0,0.10);
  border-radius: 10px;
  background: #ffffff;
}

.daz-ssr-drawer-item-ref {
  font-size: 13px;
  font-weight: 700;
}

.daz-ssr-drawer-ref-link {
  color: inherit;
  text-decoration: underline;
  cursor: pointer;
}

.daz-ssr-drawer-item-price {
  margin-top: 3px;
  font-size: 13px;
  opacity: 0.9;
}

.daz-ssr-drawer-item-actions {
  display: flex;
  align-items: center;
}

.daz-ssr-drawer-remove {
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid rgba(0,0,0,0.18);
  background: #ffffff;
  cursor: pointer;
  color: red;
  font-weight: 700;
  font-size: 13px;
}

.daz-ssr-drawer-remove:hover {
  background: rgba(0,0,0,0.03);
}

/* Email panel */
.daz-ssr-drawer-email {
  padding: 12px 14px;
  border-top: 1px solid rgba(0,0,0,0.08);
  background: rgba(0,0,0,0.02);
}

.daz-ssr-drawer-email-title {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 10px;
}

.daz-ssr-drawer-email-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (max-width: 640px) {
  .daz-ssr-drawer-email-grid {
    grid-template-columns: 1fr;
  }
}

.daz-ssr-drawer-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
}

.daz-ssr-drawer-input {
  width: 100%;
  padding: 10px 10px;
  border: 1px solid #d7d7d7;
  border-radius: 8px;
  background: #ffffff;
  box-sizing: border-box;
  font-size: 13px;
}

.daz-ssr-drawer-email-actions {
  margin-top: 10px;
}

.daz-ssr-drawer-send {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #25d366;
  background: #ffffff;
  color: #25d366;
  cursor: pointer;
  font-size: 13px;
}

.daz-ssr-drawer-send:disabled {
  opacity: 0.7;
  cursor: default;
}

.daz-ssr-drawer-email-status {
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.35;
}

.daz-ssr-drawer-share {
  margin-top: 10px;
}

.daz-ssr-drawer-share-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.daz-ssr-drawer-share-actions > * {
  flex: 1 1 auto;
  text-align: center;
  margin: 0;
}

/* Drawer WhatsApp */
a.daz-ssr-drawer-wa {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  background: #25d366;
  padding: 12px 14px;
  color: #ffffff;
  border-radius: 10px;
  border: 1px solid #000000;
  text-decoration: none;
  line-height: 1.2;
}

a.daz-ssr-drawer-wa:hover {
  text-decoration: none;
}

/* Saved bar must sit above theme floating CTAs */
.daz-ssr-savedbar {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 999999;
}

/* Drawer overlay must be above everything */
.daz-ssr-drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000000;
}

	/* When drawer is open, prevent background scroll */
	html.daz-ssr-drawer-open,
	body.daz-ssr-drawer-open {
	  overflow: hidden;
	}

  /* ============================
     D) Token page remove button placed beside "View More"
     ============================ */

  body.daz-ssr .mls-pyc-btn-wrapper {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
  }

  body.daz-ssr .mls-pyc-btn-wrapper .daz-ssr-remove-row {
    margin: 0 !important;
    padding: 0 !important;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
  }

  body.daz-ssr .mls-pyc-btn-wrapper .daz-ssr-remove-btn {
    max-width: none !important;
    padding: 11px 30px;
    white-space: nowrap;
    font-size: 18px;
    font-weight: 500;
  }
  
/* ============================
   D) Token page: View More + Remove (no stretching, responsive)
   ============================ */

/* Keep MLS layout intact, just control the CTA row */
body.daz-ssr .mls-pyc-btn-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-start; /* CRITICAL: stops vertical stretch */
}

/* Fix MLS "View More" stretching behaviour on token pages */
body.daz-ssr .mls-pyc-btn-wrapper > a.mls-button.mls-pyc-button {
  height: auto !important;          /* CRITICAL: prevents tall blue block */
  align-self: flex-start;           /* CRITICAL */
  display: inline-flex !important;  /* keeps button styling but prevents weird block fill */
  justify-content: center;
  align-items: center;
  flex: 1 1 260px;                  /* side-by-side when space allows */
  margin: 0 !important;
}

/* Make remove row behave like a sibling "button slot" */
body.daz-ssr .mls-pyc-btn-wrapper .daz-ssr-remove-row {
  margin: 0 !important;
  padding: 0 !important;
  flex: 1 1 260px;                  /* side-by-side when space allows */
  display: flex;
  align-items: flex-start;
}

/* Full-width inside its slot */
body.daz-ssr .mls-pyc-btn-wrapper .daz-ssr-remove-btn {
  width: 100% !important;
  max-width: none !important;
  display: inline-flex;
  justify-content: center;
  align-items: center;
}

/* On narrow layouts: stack them neatly (prevents “push into content”) */
@media (max-width: 900px) {
  body.daz-ssr .mls-pyc-btn-wrapper > a.mls-button.mls-pyc-button,
  body.daz-ssr .mls-pyc-btn-wrapper .daz-ssr-remove-row {
    flex: 1 1 100%;
  }
}

	/* ============================
	   C) Mobile/Tablet: keep Save UI visible (bottom sheet)
	   ============================ */

	@media (max-width: 1024px) {

	  /*
	  	IMPORTANT:
	  	Some tablet breakpoints in your theme/MLS CTA stack may hide the container
	  	where the shortcode widget lives. This makes the widget persist regardless
	  	of where it was injected by moving it to a fixed bottom sheet.
	  */

	  .daz-ssr-widget {
	    position: fixed;
	    left: 12px;
	    right: 12px;
	    bottom: 12px;
	    z-index: 1000001; /* above theme CTAs + above saved bar */
	    width: auto;
	  }

	  .daz-ssr-panel {
	    margin-top: 0;
	    background: #ffffff;
	    border: 1px solid rgba(0,0,0,0.12);
	    border-radius: 14px;
	    box-shadow: 0 14px 34px rgba(0,0,0,0.18);
	    padding: 12px;

	    /* keep it usable on small screens */
	    max-height: 65vh;
	    overflow: auto;
	  }

	  /* Ensure the primary action is always easy to hit */
	  .daz-ssr-save-btn {
	    width: 100%;
	  }

	  /* Keep the "Saved (n)" link readable/tappable */
	  .daz-ssr-open-saved {
	    display: inline-block;
	    width: 100%;
	    text-align: center;
	    margin-top: 10px;
	  }

	  /*
	  	If the sticky saved bar is also present, keep it out of the way.
	  	We move the saved bar slightly above the bottom sheet.
	  */
	  .daz-ssr-savedbar {
	    bottom: calc(12px + 140px);
	  }
	}

	@media (max-width: 520px) {
	  /* On very small screens, reduce spacing so it fits comfortably */
	  .daz-ssr-panel {
	    max-height: 60vh;
	  }
	}

