/* ============================================================
   RealtorPool — Shared Design System
   assets/css/app.css
   Loaded on every public page via includes/header.php
   ============================================================ */

/* ── DESIGN TOKENS ── */
:root {
  --gold:        #C9A84C;
  --gold-light:  #E8C97A;
  --gold-dim:    rgba(201,168,76,0.15);
  --ink:         #0E0E0E;
  --ink-soft:    #1C1C1E;
  --ink-muted:   #3A3A3C;
  --cream:       #FAF7F2;
  --cream-dark:  #F0EBE1;
  --white:       #FFFFFF;
  --border:      rgba(201,168,76,0.25);
  --shadow:      0 8px 40px rgba(0,0,0,0.12);
  --shadow-lg:   0 24px 80px rgba(0,0,0,0.18);
  --r:           12px;
}

/* ── RESET & BASE ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'DM Sans', sans-serif;
  background: var(--cream);
  color: var(--ink);
  overflow-x: hidden;
}

/* noise texture overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: 0.4;
}

/* ── NAVBAR ── */
nav#rp-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 72px;
  background: rgba(250,247,242,0.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s;
}
nav#rp-nav.scrolled { box-shadow: var(--shadow); }

.nav-logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}
.nav-logo span { color: var(--gold); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}
.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-muted);
  text-decoration: none;
  letter-spacing: 0.02em;
  transition: color 0.2s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--gold); }

.nav-cta { display: flex; gap: 12px; flex-shrink: 0; }

/* ── BUTTON SYSTEM ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  border: none;
  line-height: 1;
}
.btn-outline {
  border: 1.5px solid var(--border);
  background: transparent;
  color: var(--ink);
}
.btn-outline:hover { border-color: var(--gold); color: var(--gold); }

.btn-gold {
  background: var(--gold);
  color: var(--white);
  box-shadow: 0 2px 12px rgba(201,168,76,0.4);
}
.btn-gold:hover {
  background: var(--gold-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(201,168,76,0.5);
  color: var(--white);
}

.btn-white {
  background: var(--white);
  color: var(--gold);
  font-weight: 700;
}
.btn-white:hover { background: var(--cream); transform: translateY(-2px); }

.btn-transparent {
  background: rgba(255,255,255,0.15);
  color: var(--white);
  border: 1.5px solid rgba(255,255,255,0.4);
}
.btn-transparent:hover { background: rgba(255,255,255,0.25); }

.btn-sm { padding: 7px 14px; font-size: 0.8rem; }
.btn-lg { padding: 14px 32px; font-size: 1rem; border-radius: 10px; }

/* ── BADGE SYSTEM ── */
.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.badge-rent    { background: rgba(14,14,14,0.75); color: var(--white); backdrop-filter: blur(8px); }
.badge-sale    { background: var(--gold); color: var(--white); }
.badge-lease   { background: rgba(14,14,14,0.75); color: var(--white); backdrop-filter: blur(8px); }
.badge-verified { background: rgba(16,185,129,0.9); color: var(--white); backdrop-filter: blur(8px); }
.badge-featured { background: var(--gold); color: var(--white); }
.badge-pending  { background: rgba(245,158,11,0.9); color: var(--white); }
.badge-rejected { background: rgba(239,68,68,0.9); color: var(--white); }
.badge-active   { background: rgba(16,185,129,0.9); color: var(--white); }

/* ── PROPERTY CARD ── */
.property-card {
  background: var(--white);
  border-radius: var(--r);
  overflow: hidden;
  border: 1px solid var(--cream-dark);
  transition: all 0.3s cubic-bezier(0.34,1.56,0.64,1);
  text-decoration: none;
  color: inherit;
  display: block;
}
.property-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border);
  color: inherit;
}

.property-image {
  position: relative;
  height: 220px;
  overflow: hidden;
  background: var(--cream-dark);
}
.property-image img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.property-card:hover .property-image img { transform: scale(1.05); }

.property-badges {
  position: absolute;
  top: 12px; left: 12px;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.property-save {
  position: absolute;
  top: 12px; right: 12px;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
}
.property-save:hover { background: var(--white); transform: scale(1.1); }

.property-body { padding: 20px; }
.property-type {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 8px;
}
.property-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.3;
  margin-bottom: 8px;
}
.property-location {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.8rem;
  color: var(--ink-muted);
  margin-bottom: 16px;
}
.property-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  border-top: 1px solid var(--cream-dark);
}
.property-price {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--ink);
}
.property-area {
  font-size: 0.78rem;
  color: var(--ink-muted);
  font-weight: 500;
}

.no-image-placeholder {
  width: 100%; height: 100%;
  background: linear-gradient(135deg, var(--cream-dark), var(--cream));
  display: flex; align-items: center; justify-content: center;
  font-size: 2.5rem;
}

/* ── SECTION HEADERS ── */
.section-header { margin-bottom: 48px; }
.section-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 12px;
}
.section-header h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.2;
}
.section-header p {
  margin-top: 12px;
  font-size: 1rem;
  color: var(--ink-muted);
  max-width: 480px;
  line-height: 1.6;
}

/* ── FOOTER ── */
footer#rp-footer {
  background: var(--ink-soft);
  color: rgba(255,255,255,0.6);
  padding: 64px 48px 32px;
  position: relative;
  z-index: 1;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand .nav-logo { color: var(--white); display: block; margin-bottom: 16px; font-size: 1.4rem; }
.footer-brand p { font-size: 0.85rem; line-height: 1.7; max-width: 280px; }
.footer-col h4 {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 20px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { font-size: 0.85rem; color: rgba(255,255,255,0.5); text-decoration: none; transition: color 0.2s; }
.footer-col a:hover { color: var(--gold); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
}
.footer-tagline { color: var(--gold); font-weight: 500; }

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.5; transform: scale(0.8); }
}
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ── FLASH / ALERT ── */
.flash {
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 20px;
}
.flash-success { background: rgba(16,185,129,0.12); color: #065f46; border: 1px solid rgba(16,185,129,0.3); }
.flash-error   { background: rgba(239,68,68,0.10);  color: #7f1d1d; border: 1px solid rgba(239,68,68,0.3); }

/* ── FORM ELEMENTS (shared base) ── */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-muted);
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}
.form-control {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--cream-dark);
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--white);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-control:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-dim);
}
.form-control::placeholder { color: #b0a898; }

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  nav#rp-nav { padding: 0 20px; }
  .nav-links { display: none; }
  footer#rp-footer { padding: 48px 24px 24px; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}
