/* =========================================================
   YR LISTINGS - PUBLIC PAGE
   ========================================================= */

.yrls-page,
.yrls-page * {
  box-sizing: border-box;
}

.yrls-page {
  --yrls-navy: #061a33;
  --yrls-navy-2: #0a315c;
  --yrls-blue: #0b72b9;
  --yrls-blue-2: #1599d5;
  --yrls-aqua: #39c4e4;
  --yrls-white: #ffffff;
  --yrls-ink: #172033;
  --yrls-gray: #64748b;
  --yrls-border: rgba(6, 26, 51, 0.12);
  --yrls-shadow: 0 22px 55px rgba(6, 26, 51, 0.12);

  width: 100vw;
  max-width: 100vw;
  margin: 0 calc(50% - 50vw);
  overflow-x: clip;
  color: var(--yrls-ink);
  background: #f7fbff;
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
}

.yrls-page a {
  text-decoration: none;
}

.yrls-container {
  width: min(1440px, calc(100% - 64px));
  margin: 0 auto;
}

.yrls-hero {
  position: relative;
  overflow: hidden;
  padding: 84px 0 112px;
  color: var(--yrls-white);
  background:
    radial-gradient(circle at 88% 12%, rgba(57, 196, 228, 0.28), transparent 30%),
    linear-gradient(135deg, var(--yrls-blue), var(--yrls-navy));
}

.yrls-hero::after {
  content: "";
  position: absolute;
  top: -210px;
  right: -160px;
  width: 520px;
  height: 520px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  pointer-events: none;
}

.yrls-hero-inner {
  position: relative;
  z-index: 2;
  max-width: 900px;
}

.yrls-kicker,
.yrls-results-heading span {
  display: inline-block;
  color: var(--yrls-aqua);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.yrls-hero h1 {
  max-width: 900px;
  margin: 14px 0 0;
  color: var(--yrls-white);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(46px, 5vw, 76px);
  font-weight: 900;
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.yrls-hero p {
  max-width: 720px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 18px;
  line-height: 1.7;
}

.yrls-filter-section {
  position: relative;
  z-index: 5;
  margin-top: -62px;
}

.yrls-filter-form {
  padding: 26px;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(6, 26, 51, 0.10);
  border-radius: 28px;
  box-shadow: 0 26px 65px rgba(6, 26, 51, 0.15);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.yrls-filter-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 22px;
  padding-bottom: 19px;
  border-bottom: 1px solid rgba(6, 26, 51, 0.09);
}

.yrls-filter-header > div {
  min-width: 0;
}

.yrls-filter-kicker {
  display: inline-block;
  color: var(--yrls-blue);
  font-size: 10px;
  font-weight: 900;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.yrls-filter-header h2 {
  margin: 5px 0 0;
  color: var(--yrls-navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(24px, 2.3vw, 34px);
  font-weight: 900;
  line-height: 1.06;
  letter-spacing: -0.03em;
}

.yrls-filter-header p {
  max-width: 490px;
  margin: 0;
  color: var(--yrls-gray);
  font-size: 13px;
  line-height: 1.55;
}

.yrls-filter-grid {
  display: grid;
  grid-template-columns: 1.35fr repeat(6, minmax(112px, 1fr));
  align-items: end;
  gap: 13px;
}

.yrls-field,
.yrls-filter-actions {
  min-width: 0;
}

.yrls-field label {
  display: block;
  margin-bottom: 7px;
  color: var(--yrls-navy);
  font-size: 10px;
  font-weight: 900;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.075em;
}

.yrls-field select {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  padding: 0 38px 0 13px;
  color: var(--yrls-ink);
  background-color: #f7fbff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23061a33' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  border: 1px solid rgba(6, 26, 51, 0.14);
  border-radius: 13px;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.2;
  box-shadow: 0 5px 14px rgba(6, 26, 51, 0.035);
  transition:
    background-color 0.22s ease,
    border-color 0.22s ease,
    box-shadow 0.22s ease;
}

.yrls-field select:hover {
  background-color: #ffffff;
  border-color: rgba(11, 114, 185, 0.30);
}

.yrls-field select:focus {
  background-color: #ffffff;
  border-color: var(--yrls-blue);
  box-shadow: 0 0 0 4px rgba(11, 114, 185, 0.10);
}

.yrls-filter-actions {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 4px;
}

.yrls-search-button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 22px;
  border: 0;
  border-radius: 13px;
  cursor: pointer;
  color: var(--yrls-white);
  background:
    radial-gradient(circle at 18% 10%, rgba(57, 196, 228, 0.42), transparent 34%),
    linear-gradient(135deg, var(--yrls-blue), var(--yrls-navy));
  font-size: 13px;
  font-weight: 900;
  line-height: 1.2;
  white-space: nowrap;
  box-shadow: 0 14px 30px rgba(11, 114, 185, 0.24);
  transition:
    transform 0.22s ease,
    filter 0.22s ease,
    box-shadow 0.22s ease;
}

.yrls-search-button svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.yrls-search-button:hover {
  transform: translateY(-2px);
  filter: brightness(1.04);
  box-shadow: 0 18px 36px rgba(11, 114, 185, 0.30);
}

.yrls-reset-link {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  color: var(--yrls-gray);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.2;
  transition: color 0.22s ease;
}

.yrls-reset-link:hover {
  color: var(--yrls-blue);
}

.yrls-results-section {
  padding: 64px 0 78px;
}

.yrls-results-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 26px;
}

.yrls-results-heading h2 {
  margin: 6px 0 0;
  color: var(--yrls-navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(28px, 2.8vw, 40px);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.yrls-results-heading p {
  max-width: 520px;
  margin: 0;
  color: var(--yrls-gray);
  font-size: 14px;
  line-height: 1.65;
}

.yrls-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: start;
  justify-items: start;
  gap: 22px;
}

/*
 * Card visual hierarchy intentionally matches the Featured Properties cards
 * on the Home page, with slightly smaller dimensions for a listings archive.
 */
.yrls-card {
  width: 100%;
  max-width: 320px;
  min-width: 0;
  overflow: hidden;

  background: var(--yrls-white);
  border: 1px solid var(--yrls-border);
  border-radius: 24px;

  box-shadow: 0 12px 30px rgba(6, 26, 51, 0.08);

  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.yrls-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 50px rgba(6, 26, 51, 0.14);
}

.yrls-card-image {
  position: relative;
  display: block;

  width: 100%;
  height: 205px;

  overflow: hidden;
  background: #dceaf5;
}

.yrls-card-image img {
  width: 100%;
  height: 100%;

  object-fit: cover;

  transition: transform 0.5s ease;
}

.yrls-card:hover .yrls-card-image img {
  transform: scale(1.05);
}

.yrls-image-placeholder {
  width: 100%;
  height: 100%;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 20px;

  color: var(--yrls-navy-2);
  background: linear-gradient(135deg, #dfeef9, #f4fbff);

  font-size: 13px;
  font-weight: 800;
  text-align: center;
}

.yrls-status {
  position: absolute;
  top: 14px;
  left: 14px;

  padding: 7px 11px;

  color: var(--yrls-white);
  background: linear-gradient(135deg, var(--yrls-blue), var(--yrls-navy));

  border-radius: 999px;

  font-size: 10px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.07em;

  box-shadow: 0 8px 20px rgba(6, 26, 51, 0.16);
}

.yrls-status-pending {
  color: var(--yrls-navy);
  background: #d4a95f;
}

.yrls-status-sold,
.yrls-status-off-market {
  background: #6b7280;
}

.yrls-status-coming-soon {
  background: #7c3aed;
}

.yrls-card-body {
  padding: 20px 20px 21px;
}

.yrls-price {
  display: block;

  margin-bottom: 8px;

  color: var(--yrls-blue);

  font-size: 21px;
  font-weight: 900;
  line-height: 1.1;
}

.yrls-card h3 {
  display: -webkit-box;

  min-height: 43px;
  margin: 0;
  overflow: hidden;

  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;

  color: var(--yrls-navy);

  font-size: 17px;
  font-weight: 900;
  line-height: 1.27;
}

.yrls-card h3 a {
  color: var(--yrls-navy);
}

.yrls-card h3 a:hover {
  color: var(--yrls-blue);
}

.yrls-location {
  min-height: 19px;
  margin: 7px 0 0;

  color: var(--yrls-gray);

  font-size: 13px;
  line-height: 1.45;
}

.yrls-specs {
  display: flex;
  flex-wrap: wrap;

  gap: 7px;

  margin: 16px 0;
}

.yrls-specs span {
  padding: 7px 9px;

  color: #23405d;
  background: #edf7ff;

  border-radius: 999px;

  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
}

.yrls-card-link {
  display: inline-flex;

  padding-bottom: 4px;

  color: var(--yrls-navy);
  border-bottom: 2px solid var(--yrls-blue);

  font-size: 13px;
  font-weight: 900;
  line-height: 1.2;
}

.yrls-card-link:hover {
  color: var(--yrls-blue);
}

.yrls-empty {
  padding: 60px 28px;
  text-align: center;
  background: var(--yrls-white);
  border: 1px solid var(--yrls-border);
  border-radius: 24px;
  box-shadow: 0 14px 36px rgba(6, 26, 51, 0.07);
}

.yrls-empty h3 {
  margin: 0;
  color: var(--yrls-navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 32px;
}

.yrls-empty p {
  margin: 12px 0 20px;
  color: var(--yrls-gray);
}

.yrls-empty a {
  color: var(--yrls-blue);
  font-weight: 900;
}

.yrls-pagination {
  margin-top: 42px;
}

.yrls-pagination .page-numbers {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.yrls-pagination a,
.yrls-pagination span {
  min-width: 42px;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid var(--yrls-border);
  border-radius: 10px;
  color: var(--yrls-navy);
  background: var(--yrls-white);
  font-size: 13px;
  font-weight: 800;
}

.yrls-pagination .current,
.yrls-pagination a:hover {
  color: var(--yrls-white);
  background: var(--yrls-blue);
  border-color: var(--yrls-blue);
}

@media (max-width: 1280px) {
  .yrls-container {
    width: min(1180px, calc(100% - 48px));
  }

  .yrls-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .yrls-filter-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .yrls-field-location {
    grid-column: span 2;
  }
}

@media (max-width: 1080px) {
  .yrls-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
  }
}

@media (max-width: 900px) {
  .yrls-container {
    width: min(820px, calc(100% - 38px));
  }

  .yrls-hero {
    padding: 70px 0 100px;
  }

  .yrls-filter-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .yrls-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .yrls-field-location {
    grid-column: span 2;
  }

  .yrls-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .yrls-card {
    max-width: 100%;
  }
}

@media (max-width: 680px) {
  .yrls-page {
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
  }

  .yrls-container {
    width: calc(100% - 28px);
  }

  .yrls-hero {
    padding: 54px 0 92px;
  }

  .yrls-hero h1 {
    font-size: clamp(38px, 11vw, 50px);
  }

  .yrls-hero p {
    font-size: 15px;
  }

  .yrls-filter-section {
    margin-top: -46px;
  }

  .yrls-filter-form {
    padding: 20px;
    border-radius: 20px;
  }

  .yrls-filter-header {
    margin-bottom: 18px;
    padding-bottom: 16px;
  }

  .yrls-filter-header h2 {
    font-size: 28px;
  }

  .yrls-filter-grid {
    grid-template-columns: 1fr;
  }

  .yrls-field-location {
    grid-column: auto;
  }

  .yrls-filter-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .yrls-search-button {
    width: 100%;
  }

  .yrls-reset-link {
    width: 100%;
    text-align: center;
  }

  .yrls-results-section {
    padding: 52px 0 64px;
  }

  .yrls-results-heading {
    display: block;
  }

  .yrls-results-heading p {
    margin-top: 14px;
  }

  .yrls-grid {
    grid-template-columns: 1fr;
  }

  .yrls-card-image {
    height: 215px;
  }

  .yrls-card {
    max-width: 420px;
    margin-right: auto;
    margin-left: auto;
  }
}

@media (max-width: 420px) {
  .yrls-container {
    width: calc(100% - 22px);
  }

  .yrls-card-body {
    padding: 18px;
  }

  .yrls-card-image {
    height: 200px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .yrls-page *,
  .yrls-page *::before,
  .yrls-page *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
