/* Properties page styles — extends theme.css tokens */

/* Header nav active state */
.nav-active { color: var(--fg) !important; }

/* Page header */
.props-main { min-height: calc(100vh - 64px); }

.props-header {
  padding: 48px 32px 32px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-surface);
}

.props-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.props-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin: 12px 0 8px;
  line-height: 1.1;
}

.props-subtitle {
  font-size: 0.9375rem;
  color: var(--fg-muted);
  line-height: 1.6;
}

.btn-alert-open {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 10px 20px;
  font-family: var(--font-display);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: opacity 0.2s;
  letter-spacing: -0.01em;
  flex-shrink: 0;
}
.btn-alert-open:hover { opacity: 0.85; }

/* Filters bar */
.filters-bar {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 16px 32px;
  position: sticky;
  top: 64px;
  z-index: 50;
  backdrop-filter: blur(12px);
}

.filters-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.filter-label {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--fg-subtle);
}

.filter-select {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 0.875rem;
  padding: 8px 28px 8px 10px;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%239a958d' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  min-width: 130px;
  transition: border-color 0.2s;
}
.filter-select:focus {
  outline: none;
  border-color: var(--accent);
}

.btn-filter-apply {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 9px 20px;
  font-family: var(--font-display);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
  margin-top: 16px;
}
.btn-filter-apply:hover { opacity: 0.85; }

.btn-filter-reset {
  background: transparent;
  color: var(--fg-muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 9px 16px;
  font-family: var(--font-body);
  font-size: 0.875rem;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  margin-top: 16px;
}
.btn-filter-reset:hover { color: var(--fg); border-color: rgba(240,237,232,0.2); }

/* Results area */
.results-area {
  padding: 32px 32px 80px;
}

.results-inner {
  max-width: 1200px;
  margin: 0 auto;
}

.results-meta {
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.results-count {
  font-family: var(--font-display);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--fg-muted);
  letter-spacing: -0.01em;
}

/* Property grid */
.property-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}

/* Property card */
.prop-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 0.2s, transform 0.15s;
  cursor: default;
}
.prop-card:hover {
  border-color: rgba(255, 107, 53, 0.25);
  transform: translateY(-2px);
}

.prop-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.prop-source {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--fg-subtle);
}

.fresh-badge {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--green);
  background: rgba(74, 222, 128, 0.1);
  border: 1px solid rgba(74, 222, 128, 0.2);
  padding: 2px 8px;
  border-radius: 4px;
}

.prop-address {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--fg);
  letter-spacing: -0.01em;
  line-height: 1.3;
  margin: 0;
}

.prop-meta {
  font-size: 0.8125rem;
  color: var(--fg-muted);
  line-height: 1.4;
}

.prop-value {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.03em;
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.prop-value-label {
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--fg-subtle);
  font-family: var(--font-body);
  letter-spacing: 0;
}
.prop-value-unknown {
  color: var(--fg-subtle);
  font-size: 0.9375rem;
}

.prop-signals {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.signal-badge {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  padding: 3px 8px;
  border-radius: 4px;
}
.signal-city-owned    { background: rgba(255,107,53,0.1); color: #ff6b35; }
.signal-tax-delinquent { background: rgba(251,191,36,0.12); color: #fbbf24; }
.signal-pre-foreclosure { background: rgba(239,68,68,0.12); color: #ef4444; }
.signal-vacant        { background: rgba(156,163,175,0.12); color: #9ca3af; }
.signal-poor-condition { background: rgba(168,85,247,0.12); color: #a855f7; }

.prop-tax-note {
  font-size: 0.8125rem;
  color: #fbbf24;
  margin: 0;
}

/* Load more */
.load-more-wrap {
  justify-content: center;
  padding: 40px 0 0;
}

.btn-load-more {
  background: transparent;
  color: var(--fg-muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 12px 32px;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.btn-load-more:hover { color: var(--fg); border-color: rgba(240,237,232,0.2); }

/* Empty state */
.empty-state {
  text-align: center;
  padding: 80px 24px;
}
.empty-icon { font-size: 3rem; margin-bottom: 16px; }
.empty-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0 0 12px;
}
.empty-body {
  font-size: 0.9375rem;
  color: var(--fg-muted);
}
.empty-body a { color: var(--accent); text-decoration: none; }
.empty-body a:hover { text-decoration: underline; }

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(8, 9, 13, 0.85);
  backdrop-filter: blur(6px);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.modal-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  width: 100%;
  max-width: 460px;
  position: relative;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.modal-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--fg);
  letter-spacing: -0.02em;
  margin: 0;
}

.modal-close {
  background: transparent;
  border: none;
  color: var(--fg-muted);
  font-size: 1.125rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: color 0.2s;
}
.modal-close:hover { color: var(--fg); }

.modal-desc {
  font-size: 0.9375rem;
  color: var(--fg-muted);
  margin-bottom: 24px;
  line-height: 1.6;
}

.alert-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--fg-muted);
}

.form-label .required { color: var(--accent); }

.form-input {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  padding: 10px 12px;
  transition: border-color 0.2s;
  width: 100%;
}
.form-input::placeholder { color: var(--fg-subtle); }
.form-input:focus { outline: none; border-color: var(--accent); }

.alert-filter-preview {
  display: none;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
}
.filter-preview-label {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--fg-subtle);
  margin: 0 0 4px;
}
.filter-preview-value {
  font-size: 0.9375rem;
  color: var(--fg-muted);
  margin: 0;
}

.btn-submit-alert {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 12px 24px;
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
  letter-spacing: -0.01em;
  margin-top: 4px;
}
.btn-submit-alert:hover { opacity: 0.85; }
.btn-submit-alert:disabled { opacity: 0.5; cursor: not-allowed; }

.alert-success {
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 0 8px;
  gap: 12px;
}
.success-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(74,222,128,0.12);
  color: var(--green);
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}
.success-text {
  font-size: 0.9375rem;
  color: var(--fg-muted);
  line-height: 1.6;
  margin: 0;
  max-width: 300px;
}

/* Responsive */
@media (max-width: 900px) {
  .props-header { padding: 32px 24px 24px; }
  .filters-bar { padding: 12px 24px; }
  .results-area { padding: 24px 24px 60px; }
  .property-grid { grid-template-columns: 1fr; }
  .filters-inner { gap: 10px; }
}
@media (max-width: 600px) {
  .filter-select { min-width: 100px; }
  .props-header-inner { flex-direction: column; align-items: flex-start; }
  .btn-alert-open { width: 100%; justify-content: center; }
}
