/* ============================================================
   RCI Real Estate - main stylesheet
   Purple-themed, modern, responsive (desktop + mobile)
   ============================================================ */

:root {
  --purple-900: #4c1d95;
  --purple-800: #5b21b6;
  --purple-700: #6d28d9;
  --purple-600: #7c3aed;
  --purple-500: #8b5cf6;
  --purple-200: #ddd6fe;
  --purple-100: #ede9fe;
  --purple-50:  #f5f3ff;
  --ink:    #1e1b4b;
  --muted:  #6b7280;
  --bg:     #faf9ff;
  --white:  #ffffff;
  --green:  #25d366;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow:     0 10px 30px rgba(76, 29, 149, 0.08);
  --shadow-lg:  0 20px 50px rgba(76, 29, 149, 0.18);
  --transition: 0.25s ease;
}

/* ---------- Reset & base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition);
}

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: 1160px;
  margin-inline: auto;
  padding-inline: 20px;
}

.section {
  padding: 80px 0;
}

.section-alt {
  background: var(--white);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border: 0;
  border-radius: 999px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--purple-600), var(--purple-500));
  color: var(--white);
  box-shadow: 0 8px 20px rgba(124, 58, 237, 0.35);
}

.btn-primary:hover {
  box-shadow: 0 12px 26px rgba(124, 58, 237, 0.45);
}

.btn-outline {
  background: transparent;
  color: var(--purple-700);
  border: 2px solid var(--purple-200);
}

.btn-outline:hover {
  border-color: var(--purple-600);
  background: var(--purple-50);
}

.btn-accent {
  background: var(--white);
  color: var(--purple-800);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
}

.btn-whatsapp {
  background: var(--green);
  color: var(--white);
  box-shadow: 0 8px 20px rgba(37, 211, 102, 0.35);
}

.btn-ghost {
  background: transparent;
  color: var(--purple-700);
  border: 2px solid var(--purple-200);
}

.btn-lg {
  padding: 14px 34px;
  font-size: 1rem;
}

.btn-block {
  width: 100%;
}

.btn-header {
  padding: 10px 22px;
  font-size: 0.9rem;
}

/* We need the icon (svg) inside buttons to scale correctly */
.btn svg {
  width: 20px;
  height: 20px;
  flex: none;
}

/* ---------- Header & navigation ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--purple-100);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  padding-block: 16px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
}

.logo-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--purple-700), var(--purple-500));
  color: var(--white);
  box-shadow: 0 6px 16px rgba(124, 58, 237, 0.35);
}

.logo-icon svg {
  width: 24px;
  height: 24px;
}

.logo-text {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--purple-900);
  letter-spacing: 0.02em;
}

.logo-text em {
  font-style: normal;
  font-weight: 500;
  color: var(--purple-600);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
}

.nav-link:hover {
  background: var(--purple-50);
  color: var(--purple-700);
}

.nav-link.active {
  background: var(--purple-600);
  color: var(--white);
}

/* Hamburger (mobile only) */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 1px solid var(--purple-200);
  border-radius: var(--radius-sm);
  background: var(--white);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--purple-700);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

.nav-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero (home page) ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 96px 0 110px;
  text-align: center;
  color: var(--white);
  background: linear-gradient(160deg, var(--purple-900) 0%, var(--purple-600) 55%, var(--purple-500) 100%);
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.hero::before {
  width: 420px;
  height: 420px;
  top: -160px;
  right: -120px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.18), transparent 65%);
}

.hero::after {
  width: 360px;
  height: 360px;
  bottom: -140px;
  left: -110px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.14), transparent 65%);
}

.hero-inner {
  position: relative;
  z-index: 1;
}

.hero-eyebrow {
  display: inline-block;
  padding: 7px 18px;
  margin-bottom: 22px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hero-title {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 18px;
}

.hero-title span {
  color: #e9d5ff;
}

.hero-sub {
  max-width: 620px;
  margin-inline: auto;
  font-size: 1.1rem;
  color: rgba(245, 243, 255, 0.92);
}

/* Search bar inside the hero */
.hero-search {
  display: flex;
  gap: 6px;
  max-width: 580px;
  margin: 32px auto 0;
  padding: 6px;
  background: var(--white);
  border-radius: 999px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.22);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  padding: 12px 18px;
  border: 0;
  border-radius: 999px;
  font-family: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: transparent;
  outline: none;
}

.hero-search input::placeholder {
  color: #9ca3af;
}

/* Stats row */
.hero-stats {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 24px 60px;
  margin-top: 48px;
}

.hero-stats strong {
  display: block;
  font-size: 1.8rem;
  font-weight: 800;
}

.hero-stats span {
  font-size: 0.9rem;
  color: rgba(245, 243, 255, 0.85);
}

/* ---------- Page hero (inner pages) ---------- */
.page-hero {
  padding: 64px 0 70px;
  text-align: center;
  color: var(--white);
  background: linear-gradient(160deg, var(--purple-900), var(--purple-600) 70%, var(--purple-500));
}

.page-hero h1 {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 800;
}

.page-hero p {
  max-width: 600px;
  margin: 12px auto 0;
  color: rgba(245, 243, 255, 0.92);
}

/* ---------- Section headings ---------- */
.section-head {
  max-width: 640px;
  margin: 0 auto 48px;
  text-align: center;
}

.section-tag {
  display: inline-block;
  margin-bottom: 10px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--purple-600);
}

.section-head h2 {
  font-size: clamp(1.7rem, 3.5vw, 2.4rem);
  font-weight: 800;
  color: var(--purple-900);
}

.section-head p {
  margin-top: 12px;
  color: var(--muted);
}

/* ---------- Property cards ---------- */
.properties-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 28px;
}

.property-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--purple-100);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
}

.property-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.property-img {
  position: relative;
  display: grid;
  place-items: center;
  height: 200px;
  overflow: hidden;
}

.property-img img {
  width: 150px;
  height: auto;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.2));
}

/* Gradient backgrounds (choose one per property in the data file) */
.img-violet  { background: linear-gradient(135deg, #7c3aed, #a78bfa); }
.img-indigo  { background: linear-gradient(135deg, #4338ca, #818cf8); }
.img-blue    { background: linear-gradient(135deg, #1d4ed8, #7dd3fc); }
.img-magenta { background: linear-gradient(135deg, #a21caf, #f0abfc); }
.img-green   { background: linear-gradient(135deg, #059669, #86efac); }
.img-cyan    { background: linear-gradient(135deg, #0e7490, #67e8f9); }

.badge {
  position: absolute;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
}

.badge-type {
  top: 14px;
  left: 14px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--purple-700);
}

.badge-price {
  bottom: 14px;
  left: 14px;
  background: rgba(76, 29, 149, 0.92);
  color: var(--white);
}

.property-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 22px;
}

.property-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--purple-900);
}

.property-location {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  font-size: 0.9rem;
  color: var(--muted);
}

.property-location svg {
  width: 16px;
  height: 16px;
  color: var(--purple-500);
  flex: none;
}

.property-desc {
  margin-top: 12px;
  font-size: 0.88rem;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.property-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin: 16px 0 20px;
  padding-top: 16px;
  border-top: 1px solid var(--purple-100);
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
}

.meta-item svg {
  width: 18px;
  height: 18px;
  color: var(--purple-600);
  flex: none;
}

/* ---------- Feature / value cards (home + about) ---------- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 26px;
}

.feature-card {
  padding: 32px 26px;
  background: var(--white);
  border: 1px solid var(--purple-100);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.feature-icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  margin-bottom: 18px;
  border-radius: 16px;
  font-size: 1.6rem;
  background: var(--purple-50);
  border: 1px solid var(--purple-100);
}

.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--purple-900);
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 0.9rem;
  color: var(--muted);
}

/* ---------- Call-to-action band ---------- */
.cta-band {
  padding: 72px 0;
  color: var(--white);
  text-align: center;
  background: linear-gradient(135deg, var(--purple-900), var(--purple-600));
}

.cta-band h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 800;
}

.cta-band p {
  max-width: 560px;
  margin: 12px auto 30px;
  color: rgba(245, 243, 255, 0.9);
}

.cta-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
}

/* ---------- Filter bar (properties page) ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 760px;
  margin: -30px auto 44px; /* overlaps the page hero slightly */
  padding: 14px;
  background: var(--white);
  border: 1px solid var(--purple-100);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.filter-bar input,
.filter-bar select {
  flex: 1;
  min-width: 180px;
  padding: 11px 16px;
  border: 1px solid var(--purple-200);
  border-radius: 999px;
  font-family: inherit;
  font-size: 0.92rem;
  color: var(--ink);
  background: var(--white);
  outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--purple-600);
  box-shadow: 0 0 0 3px var(--purple-100);
}

.results-count {
  margin-bottom: 24px;
  text-align: center;
  font-size: 0.92rem;
  color: var(--muted);
}

.empty-state {
  padding: 60px 24px;
  text-align: center;
  background: var(--white);
  border: 1px dashed var(--purple-200);
  border-radius: var(--radius);
  color: var(--muted);
}

.empty-state h3 {
  color: var(--purple-900);
  margin-bottom: 8px;
}

/* ---------- About page ---------- */
.story-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.story-img {
  display: grid;
  place-items: center;
  min-height: 320px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--purple-600), var(--purple-300));
  box-shadow: var(--shadow-lg);
}

.story-img img {
  width: 220px;
  height: auto;
}

.story-text h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: var(--purple-900);
  margin-bottom: 16px;
}

.story-text p {
  color: var(--muted);
  margin-bottom: 14px;
}

.mission-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 26px;
}

/* ---------- Contact page ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 40px;
  align-items: start;
}

.info-cards {
  display: grid;
  gap: 20px;
}

.info-card {
  display: flex;
  gap: 16px;
  padding: 22px;
  background: var(--white);
  border: 1px solid var(--purple-100);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.info-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  flex: none;
  border-radius: 14px;
  font-size: 1.3rem;
  background: var(--purple-50);
}

.info-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--purple-900);
}

.info-card p,
.info-card a {
  font-size: 0.92rem;
  color: var(--muted);
}

.info-card a:hover {
  color: var(--purple-600);
}

/* Contact form */
.contact-form {
  padding: 32px;
  background: var(--white);
  border: 1px solid var(--purple-100);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 18px;
}

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--purple-900);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--purple-200);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--white);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--purple-600);
  box-shadow: 0 0 0 3px var(--purple-100);
}

.form-note {
  margin-top: 12px;
  font-size: 0.82rem;
  color: var(--muted);
}

/* Alerts (e.g. "Message sent" success box) */
.alert {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 24px;
  padding: 16px 20px;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  opacity: 1;
  transition: opacity 0.4s ease;
}

.alert.hide {
  opacity: 0;
}

.alert-success {
  background: #d1fae5;
  border: 1px solid #6ee7b7;
  color: #065f46;
}

.alert-error {
  background: #fee2e2;
  border: 1px solid #fca5a5;
  color: #991b1b;
}

.alert ul {
  margin: 8px 0 0 20px;
}

.alert ul li {
  list-style: disc;
}

.whatsapp-wrap {
  margin-top: 28px;
  text-align: center;
}

/* ---------- Footer ---------- */
.site-footer {
  background: linear-gradient(160deg, #2e1065, #4c1d95);
  color: #ddd6fe;
  padding-top: 64px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.2fr;
  gap: 40px;
  padding-bottom: 48px;
}

.footer-logo {
  display: inline-block;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--white);
}

.footer-logo em {
  font-style: normal;
  font-weight: 500;
  color: #c4b5fd;
}

.footer-col h4 {
  margin-bottom: 16px;
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
}

.footer-col p,
.footer-col li {
  font-size: 0.92rem;
  line-height: 1.8;
}

.footer-col a:hover {
  color: var(--white);
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-bottom {
  padding: 20px 0;
  border-top: 1px solid rgba(221, 214, 254, 0.2);
  text-align: center;
  font-size: 0.85rem;
  color: #c4b5fd;
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .section {
    padding: 64px 0;
  }

  .story-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 860px) {
  .header-inner {
    gap: 14px;
  }

  .btn-header {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .main-nav {
    position: absolute;
    top: calc(100% + 8px);
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 14px;
    background: var(--white);
    border: 1px solid var(--purple-100);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
  }

  .main-nav.nav-open {
    display: flex;
  }

  .nav-link {
    padding: 12px 16px;
    text-align: center;
  }

  .hero {
    padding: 72px 0 84px;
  }
}

@media (max-width: 640px) {
  .hero-search {
    flex-direction: column;
    border-radius: 24px;
  }

  .hero-search .btn {
    width: 100%;
  }

  .hero-stats {
    gap: 20px 32px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .filter-bar {
    margin-top: 0; /* no overlap on small screens */
  }

  .cta-actions .btn {
    width: 100%;
  }
}