/* Prima Estates — public site
   Palette: pine #1B2E26 · paper #FCFBF8 · brass #A8894B · stone #E7E3D8 · ink #26261F */

:root {
  --pine: #1b2e26;
  --pine-deep: #14231d;
  --paper: #fcfbf8;
  --brass: #a8894b;
  --brass-dark: #8c703a;
  --stone: #e7e3d8;
  --ink: #26261f;
  --muted: #6e6b60;
  --white: #ffffff;
  --radius: 10px;
  --shadow: 0 8px 30px rgba(27, 46, 38, 0.1);
  --font-display: "Marcellus", serif;
  --font-body: "Figtree", system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; line-height: 1.15; }

.container { max-width: 1180px; margin: 0 auto; padding: 0 1.25rem; }

/* ---------- Header ---------- */
.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--stone);
  position: sticky; top: 0; z-index: 50;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 0.6rem; font-family: var(--font-display); font-size: 1.35rem; }
.brand em { color: var(--brass); font-style: normal; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--pine); color: var(--paper);
  display: grid; place-items: center;
  font-size: 1.1rem;
}
.main-nav { display: flex; align-items: center; gap: 1.75rem; font-weight: 500; font-size: 0.95rem; }
.main-nav a:hover { color: var(--brass-dark); }
.nav-cta {
  border: 1px solid var(--pine); border-radius: 999px;
  padding: 0.45rem 1.1rem; transition: all 0.15s;
}
.nav-cta:hover { background: var(--pine); color: var(--paper) !important; }
.nav-toggle { display: none; background: none; border: none; font-size: 1.5rem; cursor: pointer; }

/* ---------- Hero ---------- */
.hero {
  /* Drop your photo in at wwwroot/img/hero.jpg. The gradient sits on top so the
     text stays readable whatever the photo looks like. If the file is missing,
     the gradient alone still renders and the hero looks fine. */
  background-color: var(--pine-deep);
  background-image:
    linear-gradient(rgba(20, 35, 29, 0.78), rgba(20, 35, 29, 0.86)),
    url('/img/hero.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--paper);
  padding: 6rem 0 5rem;
}
.hero-inner { text-align: center; }
.hero-eyebrow {
  text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.78rem;
  color: var(--brass); margin-bottom: 1rem; font-weight: 600;
}
.hero h1 { font-size: clamp(2rem, 5vw, 3.4rem); margin: 0 auto 2.25rem; max-width: 760px; }

.hero-search {
  background: var(--white); color: var(--ink);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 1rem 1.25rem 1.25rem; max-width: 860px; margin: 0 auto;
  text-align: left;
}
.hs-tabs { display: flex; gap: 0.5rem; margin-bottom: 0.9rem; }
.hs-tabs label { cursor: pointer; }
.hs-tabs input { display: none; }
.hs-tabs span {
  display: inline-block; padding: 0.35rem 1.15rem; border-radius: 999px;
  font-weight: 600; font-size: 0.9rem; border: 1px solid var(--stone);
}
.hs-tabs input:checked + span { background: var(--pine); color: var(--paper); border-color: var(--pine); }
.hs-fields { display: grid; grid-template-columns: 2fr 1fr 1fr auto; gap: 0.6rem; }
.hs-fields input, .hs-fields select {
  padding: 0.7rem 0.85rem; border: 1px solid var(--stone); border-radius: 8px;
  font: inherit; background: var(--paper);
}
.hs-fields button {
  padding: 0.7rem 1.6rem; border: none; border-radius: 8px;
  background: var(--brass); color: var(--white); font-weight: 700; cursor: pointer;
}
.hs-fields button:hover { background: var(--brass-dark); }

.hero-stats {
  display: flex; gap: 2.75rem; margin-top: 2.5rem;
  flex-wrap: wrap; justify-content: center;
}
.hero-stats div { display: flex; flex-direction: column; align-items: center; }
.hero-stats strong { font-family: var(--font-display); font-size: 1.5rem; color: var(--brass); }
.hero-stats span { font-size: 0.85rem; opacity: 0.75; }

/* ---------- Sections ---------- */
.section { padding: 4rem 0; }
.section-alt { background: var(--white); border-top: 1px solid var(--stone); border-bottom: 1px solid var(--stone); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 2rem; }
.section-head h2 { font-size: 1.9rem; }
.section-link { color: var(--brass-dark); font-weight: 600; font-size: 0.95rem; }

.page-head { background: var(--pine); color: var(--paper); padding: 3rem 0 2.5rem; }
.page-head h1 { font-size: 2.4rem; }
.page-head p { opacity: 0.8; margin-top: 0.4rem; }

/* ---------- Property cards ---------- */
.prop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; }
.prop-card {
  background: var(--white); border: 1px solid var(--stone); border-radius: var(--radius);
  overflow: hidden; transition: transform 0.15s, box-shadow 0.15s;
  display: flex; flex-direction: column;
}
.prop-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.prop-card-media { position: relative; aspect-ratio: 3/2; overflow: hidden; }
.prop-card-media img { width: 100%; height: 100%; object-fit: cover; }
.prop-badge {
  position: absolute; top: 0.75rem; left: 0.75rem;
  padding: 0.25rem 0.7rem; border-radius: 999px;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
}
.badge-sale { background: var(--pine); color: var(--paper); }
.badge-rent { background: #40556b; color: var(--paper); }
.badge-featured { left: auto; right: 0.75rem; background: var(--brass); color: var(--white); }
.badge-type { position: static; background: var(--stone); color: var(--ink); }
.prop-card-body { padding: 1.1rem 1.2rem 1.25rem; }
.prop-price {
  font-family: var(--font-display); font-size: 1.3rem; color: var(--pine);
  border-bottom: 2px solid var(--brass); display: inline-block;
  padding-bottom: 0.15rem; margin-bottom: 0.5rem;
}
.prop-card-body h3 { font-family: var(--font-body); font-weight: 600; font-size: 1.02rem; margin-bottom: 0.25rem; }
.prop-loc { color: var(--muted); font-size: 0.87rem; margin-bottom: 0.6rem; }
.prop-specs { display: flex; gap: 0.9rem; font-size: 0.85rem; color: var(--muted); font-weight: 500; }

/* ---------- Filter bar / listing ---------- */
.filter-bar {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 0.6rem; background: var(--white); border: 1px solid var(--stone);
  border-radius: var(--radius); padding: 1rem; margin-bottom: 2rem;
}
.filter-bar input, .filter-bar select {
  padding: 0.6rem 0.75rem; border: 1px solid var(--stone); border-radius: 8px; font: inherit;
}
.pagination { display: flex; gap: 0.4rem; justify-content: center; margin-top: 2.5rem; }
.pagination a {
  width: 38px; height: 38px; display: grid; place-items: center;
  border: 1px solid var(--stone); border-radius: 8px; font-weight: 600;
}
.pagination a.active { background: var(--pine); color: var(--paper); border-color: var(--pine); }

.empty-state { text-align: center; padding: 4rem 1rem; color: var(--muted); }
.empty-state h3, .empty-state h1 { color: var(--ink); margin-bottom: 0.5rem; }

/* ---------- Detail page ---------- */
.detail-gallery { margin-bottom: 2rem; }
.dg-main { border-radius: var(--radius); overflow: hidden; aspect-ratio: 21/9; }
.dg-main img { width: 100%; height: 100%; object-fit: cover; }
.dg-thumbs { display: flex; gap: 0.6rem; margin-top: 0.6rem; overflow-x: auto; }
.dg-thumbs img {
  width: 110px; height: 74px; object-fit: cover; border-radius: 6px;
  cursor: pointer; border: 2px solid transparent;
}
.dg-thumbs img:hover { border-color: var(--brass); }

.detail-grid { display: grid; grid-template-columns: 1.8fr 1fr; gap: 2.5rem; }
.detail-badges { display: flex; gap: 0.5rem; margin-bottom: 0.9rem; }
.detail-badges .prop-badge { position: static; }
.detail-main h1 { font-size: 2.1rem; margin-bottom: 0.3rem; }
.detail-address { color: var(--muted); margin-bottom: 1rem; }
.detail-price {
  font-family: var(--font-display); font-size: 2rem; color: var(--pine);
  margin-bottom: 1.5rem;
}
.spec-row {
  display: flex; gap: 2rem; padding: 1.15rem 1.4rem; flex-wrap: wrap;
  background: var(--white); border: 1px solid var(--stone); border-radius: var(--radius);
  margin-bottom: 2rem;
}
.spec-row div { display: flex; flex-direction: column; }
.spec-row strong { font-family: var(--font-display); font-size: 1.3rem; color: var(--pine); }
.spec-row span { font-size: 0.82rem; color: var(--muted); }
.detail-main h2 { font-size: 1.4rem; margin-bottom: 0.75rem; }
.detail-desc { white-space: pre-line; color: #3d3d35; }

.agent-card {
  display: flex; gap: 1rem; align-items: center;
  background: var(--white); border: 1px solid var(--stone);
  border-radius: var(--radius); padding: 1rem 1.2rem; margin-bottom: 1.25rem;
}
.agent-card img { width: 62px; height: 62px; border-radius: 50%; object-fit: cover; }
.agent-card div { display: flex; flex-direction: column; font-size: 0.9rem; }
.agent-card strong { font-size: 1rem; }
.agent-card span { color: var(--muted); }

.enquiry-card {
  background: var(--white); border: 1px solid var(--stone);
  border-radius: var(--radius); padding: 1.5rem;
}
.enquiry-card h3 { font-size: 1.15rem; margin-bottom: 1rem; }
.enquiry-card input, .enquiry-card textarea {
  width: 100%; padding: 0.7rem 0.85rem; border: 1px solid var(--stone);
  border-radius: 8px; font: inherit; margin-bottom: 0.75rem;
}

/* ---------- Buttons & alerts ---------- */
.btn {
  display: inline-block; padding: 0.7rem 1.5rem; border-radius: 8px;
  border: 1px solid var(--stone); background: var(--white);
  font: inherit; font-weight: 600; cursor: pointer; text-align: center;
}
.btn-primary { background: var(--pine); color: var(--paper); border-color: var(--pine); }
.btn-primary:hover { background: var(--pine-deep); }
.btn-light { background: var(--paper); color: var(--pine); border-color: var(--paper); }
.btn-block { width: 100%; }

.alert { padding: 0.8rem 1rem; border-radius: 8px; margin-bottom: 1rem; font-size: 0.92rem; }
.alert-success { background: #e8f3e8; color: #235c23; border: 1px solid #bcd9bc; }
.alert-error { background: #fbeaea; color: #8a2323; border: 1px solid #ecc4c4; }

/* ---------- Services section ---------- */
.services-section { background: var(--white); border-top: 1px solid var(--stone); }
.section-head-center { flex-direction: column; align-items: center; text-align: center; gap: 0.35rem; }
.section-sub { color: var(--muted); max-width: 520px; }

.services-layout {
  display: grid; grid-template-columns: 1fr auto 1fr;
  gap: 2rem; align-items: center; margin-top: 1rem;
}
.services-col { display: flex; flex-direction: column; gap: 1.75rem; }

.service-card {
  background: var(--pine); color: var(--paper);
  border-radius: var(--radius); padding: 1.5rem 1.6rem;
  position: relative;
}
.service-card::after {
  /* connector line pointing toward the centre figure */
  content: ""; position: absolute; top: 50%; width: 2rem; height: 2px;
  background: var(--brass); opacity: 0.7;
}
.services-col:first-child .service-card::after { right: -2rem; }
.services-col:last-child .service-card::after { left: -2rem; }

.service-icon {
  width: 46px; height: 46px; border-radius: 10px;
  background: var(--brass); color: var(--white);
  display: grid; place-items: center; margin-bottom: 0.85rem;
}
.service-icon svg { width: 24px; height: 24px; }
.service-card h3 { font-family: var(--font-body); font-weight: 700; font-size: 1.08rem; margin-bottom: 0.4rem; }
.service-card p { font-size: 0.92rem; opacity: 0.88; line-height: 1.55; }

.services-figure {
  width: 300px; align-self: stretch; display: flex; align-items: flex-end;
  background: var(--stone); border-radius: 16px; overflow: hidden;
}
.services-figure img { width: 100%; height: 100%; object-fit: cover; object-position: top; }

@media (max-width: 900px) {
  .services-layout { grid-template-columns: 1fr; }
  .services-figure { width: 100%; max-height: 340px; order: -1; }
  .service-card::after { display: none; }
}

/* ---------- CTA band ---------- */
.cta-band { background: var(--pine); color: var(--paper); }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.cta-inner h2 { font-size: 1.8rem; margin-bottom: 0.4rem; }
.cta-inner p { opacity: 0.85; max-width: 520px; }

/* ---------- Agents & contact ---------- */
.agent-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1.5rem; }
.agent-profile {
  background: var(--white); border: 1px solid var(--stone); border-radius: var(--radius);
  padding: 1.75rem 1.5rem; text-align: center;
}
.agent-profile img {
  width: 108px; height: 108px; border-radius: 50%; object-fit: cover;
  margin: 0 auto 1rem; border: 3px solid var(--stone);
}
.agent-profile h3 { font-size: 1.2rem; }
.agent-ren { color: var(--brass-dark); font-size: 0.82rem; font-weight: 600; letter-spacing: 0.05em; }
.agent-profile p { color: var(--muted); font-size: 0.9rem; margin: 0.5rem 0 0.75rem; }
.agent-contact { display: flex; flex-direction: column; gap: 0.15rem; font-size: 0.88rem; }

.contact-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 2.5rem; }
.contact-info h3 { font-size: 1.3rem; margin-bottom: 0.75rem; }
.contact-info p { margin-bottom: 0.9rem; color: #3d3d35; }

/* ---------- Login ---------- */
.login-section { display: grid; place-items: center; min-height: 60vh; }
.login-card {
  width: 100%; max-width: 400px; background: var(--white);
  border: 1px solid var(--stone); border-radius: var(--radius);
  padding: 2.25rem; box-shadow: var(--shadow);
}
.login-card h1 { font-size: 1.7rem; margin-bottom: 0.25rem; }
.login-sub { color: var(--muted); font-size: 0.92rem; margin-bottom: 1.5rem; }
.login-card label { font-weight: 600; font-size: 0.88rem; display: block; margin-bottom: 0.3rem; }
.login-card input {
  width: 100%; padding: 0.7rem 0.85rem; border: 1px solid var(--stone);
  border-radius: 8px; font: inherit; margin-bottom: 1rem;
}

/* ---------- Footer ---------- */
.site-footer { background: var(--pine-deep); color: rgba(252, 251, 248, 0.82); margin-top: 2rem; }
.footer-grid {
  display: grid; grid-template-columns: 1.6fr 1fr 1fr;
  gap: 2.5rem; padding: 3.5rem 1.25rem 2rem;
}
.footer-brand { color: var(--paper); margin-bottom: 0.75rem; }
.footer-grid h4 {
  color: var(--paper); font-size: 0.85rem; text-transform: uppercase;
  letter-spacing: 0.1em; margin-bottom: 0.9rem;
}
.footer-grid a { display: block; margin-bottom: 0.5rem; font-size: 0.92rem; }
.footer-grid a:hover { color: var(--brass); }
.footer-grid p { font-size: 0.92rem; }
.footer-bottom {
  border-top: 1px solid rgba(252, 251, 248, 0.12);
  padding: 1.25rem; font-size: 0.82rem; opacity: 0.65;
}

/* ---------- Focus & motion ---------- */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--brass); outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .detail-grid, .contact-grid, .footer-grid { grid-template-columns: 1fr; }
  .hs-fields { grid-template-columns: 1fr 1fr; }
  .hs-fields input[name="q"] { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .main-nav {
    display: none; position: absolute; top: 72px; left: 0; right: 0;
    background: var(--paper); border-bottom: 1px solid var(--stone);
    flex-direction: column; align-items: flex-start; padding: 1.25rem; gap: 1rem;
  }
  .main-nav.open { display: flex; }
  .hs-fields { grid-template-columns: 1fr; }
  .hero { padding: 3.5rem 0 3rem; }
}
