/* Meyer & Kie — Real Estate Agency, Potchefstroom
   Brand red sampled from the logo: #DE1C20 */

:root {
  --red: #de1c20;
  --red-dark: #b31419;
  --red-tint: #fdf1f1;
  --ink: #14171a;
  --ink-2: #3d4651;
  --ink-3: #6b7683;
  --line: #e3e7eb;
  --surface: #f6f7f9;
  --white: #fff;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(20, 23, 26, .06), 0 8px 24px rgba(20, 23, 26, .07);
  --shadow-lg: 0 2px 4px rgba(20, 23, 26, .06), 0 18px 48px rgba(20, 23, 26, .12);
  --wrap: 1180px;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink-2);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--red); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  color: var(--ink);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 .5em;
  font-weight: 750;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1em; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }

.eyebrow {
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--red);
  margin: 0 0 .7em;
}

.lede { font-size: 1.12rem; color: var(--ink-2); max-width: 62ch; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5em;
  padding: .78em 1.5em;
  border-radius: 8px;
  font-size: .98rem;
  font-weight: 650;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s, transform .15s;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-dark); color: #fff; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink-3); color: var(--ink); }
.btn-light { background: rgba(255,255,255,.95); color: var(--ink); }
.btn-light:hover { background: #fff; color: var(--ink); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 74px;
}
.brand { display: flex; align-items: center; }
.brand img { height: 42px; width: auto; }
.brand:hover { text-decoration: none; }

.nav { display: flex; align-items: center; gap: 28px; }
.nav a {
  color: var(--ink-2);
  font-size: .97rem;
  font-weight: 550;
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--red); text-decoration: none; }
.nav a[aria-current="page"] { font-weight: 700; }

.header-cta { display: flex; align-items: center; gap: 12px; }
.header-phone {
  font-weight: 650;
  color: var(--ink);
  font-size: .97rem;
}
.header-phone:hover { color: var(--red); text-decoration: none; }

.nav-toggle {
  display: none;
  background: none;
  border: 1.5px solid var(--line);
  border-radius: 8px;
  padding: 9px 11px;
  cursor: pointer;
  line-height: 0;
}
.nav-toggle span {
  display: block; width: 19px; height: 2px;
  background: var(--ink); border-radius: 2px;
}
.nav-toggle span + span { margin-top: 4px; }

@media (max-width: 920px) {
  .nav {
    position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    padding: 8px 22px 18px;
    box-shadow: var(--shadow);
  }
  .nav[hidden] { display: none; }
  .nav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav a:last-child { border-bottom: 0; }
  .nav-toggle { display: block; }
  .header-phone { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 560px;
  display: flex;
  align-items: flex-end;
  color: #fff;
  background: #22262b;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(185deg, rgba(10,12,14,.52) 0%, rgba(10,12,14,.30) 42%, rgba(10,12,14,.86) 100%);
}
.hero img.hero-bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero .wrap { position: relative; z-index: 2; padding-top: 110px; padding-bottom: 56px; }
.hero h1 { color: #fff; max-width: 17ch; text-shadow: 0 2px 24px rgba(0,0,0,.3); }
.hero .eyebrow { color: #fff; opacity: .9; }
.hero p {
  color: rgba(255,255,255,.93);
  font-size: 1.14rem;
  max-width: 54ch;
  text-shadow: 0 1px 16px rgba(0,0,0,.35);
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

/* ---------- Sections ---------- */
.section { padding: 76px 0; }
.section-surface { background: var(--surface); }
.section-head { margin-bottom: 38px; max-width: 70ch; }
.section-head.row {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 24px; max-width: none;
}
.section-head h2 { margin-bottom: .25em; }
.section-head p { margin: 0; color: var(--ink-3); }

/* ---------- Listing cards ---------- */
.grid {
  display: grid;
  gap: 26px;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow .18s, transform .18s, border-color .18s;
}
.card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); border-color: #d5dae0; }
.card-media { position: relative; aspect-ratio: 4 / 3; background: var(--surface); }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.card-body h3 { margin-bottom: .2em; font-size: 1.14rem; }
.card-body h3 a { color: var(--ink); }
.card-body h3 a:hover { color: var(--red); text-decoration: none; }
.card-loc {
  color: var(--ink-3);
  font-size: .92rem;
  margin: 0 0 14px;
}
.card-price {
  font-size: 1.3rem;
  font-weight: 760;
  color: var(--ink);
  letter-spacing: -0.02em;
  margin: 0 0 14px;
}
.card-price small { font-size: .78rem; font-weight: 600; color: var(--ink-3); }
.card-avail {
  font-size: .86rem;
  font-weight: 600;
  color: var(--red);
  margin: -8px 0 14px;
}
.card-foot {
  margin-top: auto;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.badge {
  position: absolute;
  top: 13px; left: 13px;
  background: var(--red);
  color: #fff;
  font-size: .72rem;
  font-weight: 750;
  letter-spacing: .09em;
  text-transform: uppercase;
  padding: .42em .78em;
  border-radius: 5px;
  z-index: 2;
}
.badge-sale { background: var(--red); }
.badge-rent { background: var(--ink); }
.badge-sold { background: #6b7683; }

/* Sold / let: still browsable, visibly off the market. */
.card-sold .card-media img { filter: grayscale(.72); opacity: .82; }
.card-sold .card-price { color: var(--ink-3); text-decoration: line-through; }
/* inline-block gives "per month" its own box, so the parent's
   line-through stops at the price itself. */
.card-sold .card-price small { display: inline-block; text-decoration: none; }

/* Listing published before its photographs arrived. */
.photo-pending {
  display: flex;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  margin: 0 0 44px;
  color: var(--ink-3);
}
.photo-pending img { width: 260px; border-radius: 7px; flex: none; }
.photo-pending span { flex: 1 1 260px; }
.badge-count {
  position: absolute;
  bottom: 13px; right: 13px;
  background: rgba(20,23,26,.74);
  color: #fff;
  font-size: .78rem;
  font-weight: 600;
  padding: .3em .66em;
  border-radius: 5px;
  z-index: 2;
}

/* Feature strip (beds / baths / garages) */
.features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: .9rem;
  color: var(--ink-2);
}
.features li { display: flex; align-items: center; gap: .45em; }
.features svg { width: 17px; height: 17px; flex: none; stroke: var(--ink-3); }
.features b { color: var(--ink); font-weight: 650; }

/* ---------- Property detail ---------- */
.prop-head { padding: 40px 0 0; }
.breadcrumb { font-size: .88rem; color: var(--ink-3); margin-bottom: 18px; }
.breadcrumb a { color: var(--ink-3); }
.breadcrumb a:hover { color: var(--red); }

.prop-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px 32px;
  margin-bottom: 26px;
}
.prop-title-row h1 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); margin-bottom: .18em; }
.prop-title-row .loc { color: var(--ink-3); margin: 0; }
.prop-price {
  font-size: clamp(1.6rem, 3.2vw, 2.1rem);
  font-weight: 780;
  color: var(--red);
  letter-spacing: -0.02em;
  white-space: nowrap;
  margin: 0;
}
.prop-price small { display: block; font-size: .8rem; font-weight: 600; color: var(--ink-3); letter-spacing: 0; }

/* Gallery */
.gallery-wrap { margin-bottom: 44px; }
.gallery-actions { margin: 14px 0 0; }
.gallery {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 10px;
  border-radius: var(--radius);
  overflow: hidden;
}
.gallery a {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--surface);
}
.gallery a:first-child { grid-row: span 2; }
.gallery img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.gallery a:hover img { transform: scale(1.04); }
.gallery a:first-child { aspect-ratio: 4 / 3; }
.gallery a:not(:first-child) { aspect-ratio: 4 / 3; }
.gallery-more {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(20,23,26,.6);
  color: #fff;
  font-weight: 700;
  font-size: 1.05rem;
}
@media (max-width: 760px) {
  /* auto rows, or the hidden 4th/5th tiles leave an empty reserved row */
  .gallery { grid-template-columns: 1fr 1fr; grid-template-rows: auto; }
  .gallery a:first-child { grid-row: span 1; grid-column: span 2; }
  .gallery a:nth-child(n+4) { display: none; }
}

.prop-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 350px;
  gap: 54px;
  align-items: start;
  padding-bottom: 80px;
}
@media (max-width: 980px) {
  .prop-layout { grid-template-columns: 1fr; gap: 40px; }
}

.prop-body h2 { font-size: 1.4rem; margin-top: 2em; }
.prop-body h2:first-child { margin-top: 0; }

/* Flex rather than grid: flex-grow lets a short last row fill the width,
   so no empty cells show the divider colour through. */
.specs {
  display: flex;
  flex-wrap: wrap;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 0 0 34px;
  list-style: none;
  padding: 0;
}
.specs li {
  background: #fff;
  flex: 1 1 150px;
  padding: 17px 20px;
}
.specs dt, .specs .k {
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--ink-3);
  font-weight: 650;
  margin-bottom: 3px;
}
.specs .v { font-size: 1.05rem; font-weight: 700; color: var(--ink); }

.tags { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 9px; }
.tags li {
  background: var(--red-tint);
  color: var(--red-dark);
  border: 1px solid #f6d9da;
  border-radius: 20px;
  padding: .35em .95em;
  font-size: .87rem;
  font-weight: 600;
}

/* Agent / enquiry card */
.sidecard {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow);
  position: sticky;
  top: 98px;
}
.sidecard h3 { font-size: 1.1rem; margin-bottom: .3em; }
.sidecard .muted { color: var(--ink-3); font-size: .93rem; }
.agent {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.agent:first-of-type { border-top: 0; padding-top: 6px; }
.agent-ini {
  width: 46px; height: 46px; flex: none;
  border-radius: 50%;
  background: var(--red-tint);
  color: var(--red);
  display: flex; align-items: center; justify-content: center;
  font-weight: 750; font-size: .98rem;
  border: 1px solid #f6d9da;
}
.agent-photo {
  width: 38px; height: 38px; flex: none;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  background: var(--surface);
  border: 1px solid var(--line);
}
.agent-card .agent-photo { width: 48px; height: 48px; margin-bottom: 14px; }
.agent-name { font-weight: 650; color: var(--ink); line-height: 1.3; }
.agent-role { font-size: .85rem; color: var(--ink-3); }
.sidecard .btn { width: 100%; justify-content: center; margin-top: 8px; }

/* ---------- Agents section ---------- */
.agent-grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.agent-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
}
.agent-card .agent-ini { width: 56px; height: 56px; font-size: 1.1rem; margin-bottom: 16px; }
.agent-card h3 { margin-bottom: .1em; }
.agent-card .agent-role { margin-bottom: 14px; }
.contact-list { list-style: none; padding: 0; margin: 0; font-size: .95rem; }
.contact-list li { display: flex; align-items: center; gap: .6em; padding: 4px 0; }
.contact-list svg { width: 16px; height: 16px; stroke: var(--ink-3); flex: none; }
.contact-list a { color: var(--ink-2); }
.contact-list a:hover { color: var(--red); }
.agent-card .btn { margin-top: 16px; }

/* ---------- Value props ---------- */
.vp-grid { display: grid; gap: 30px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.vp h3 { font-size: 1.08rem; margin-bottom: .35em; }
.vp p { color: var(--ink-3); font-size: .97rem; margin: 0; }
.vp-icon {
  width: 42px; height: 42px;
  border-radius: 9px;
  background: var(--red-tint);
  border: 1px solid #f6d9da;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
}
.vp-icon svg { width: 21px; height: 21px; stroke: var(--red); }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--ink);
  color: #fff;
  padding: 66px 0;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.76); max-width: 56ch; }
.cta-band .btn-ghost { color: #fff; border-color: rgba(255,255,255,.3); }
.cta-band .btn-ghost:hover { border-color: #fff; color: #fff; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

/* ---------- Filters ---------- */
.filterbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 34px;
}
.filterbar button {
  font: inherit;
  font-size: .94rem;
  font-weight: 600;
  padding: .55em 1.15em;
  border-radius: 20px;
  border: 1.5px solid var(--line);
  background: #fff;
  color: var(--ink-2);
  cursor: pointer;
  transition: all .15s;
}
.filterbar button:hover { border-color: var(--ink-3); }
.filterbar button[aria-pressed="true"] {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

/* ---------- Footer ---------- */
.site-footer {
  background: #0f1215;
  color: rgba(255,255,255,.62);
  padding: 58px 0 28px;
  font-size: .94rem;
}
.footer-grid {
  display: grid;
  gap: 38px;
  grid-template-columns: 1.4fr 1fr 1fr;
  padding-bottom: 38px;
}
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 30px; } }
.site-footer h4 {
  color: #fff;
  font-size: .82rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin: 0 0 16px;
  font-weight: 700;
}
.site-footer a { color: rgba(255,255,255,.7); }
.site-footer a:hover { color: #fff; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { padding: 4px 0; }
.footer-logo {
  background: #fff;
  border-radius: 7px;
  padding: 9px 13px;
  display: inline-block;
  margin-bottom: 16px;
}
.footer-logo img { height: 34px; width: auto; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12);
  padding-top: 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: .87rem;
  color: rgba(255,255,255,.45);
}

/* ---------- Forms ---------- */
.form-grid { display: grid; gap: 18px; grid-template-columns: 1fr 1fr; }
@media (max-width: 680px) { .form-grid { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: .89rem; font-weight: 650; color: var(--ink); }
.field input, .field select, .field textarea {
  font: inherit;
  font-size: 1rem;
  padding: .7em .85em;
  border: 1.5px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(222, 28, 32, .12);
}
.field textarea { resize: vertical; min-height: 130px; }
.form-note { font-size: .88rem; color: var(--ink-3); margin-top: 14px; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0;
  background: rgba(8, 10, 12, .94);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 20px;
}
.lightbox[hidden] { display: none; }
.lightbox img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 6px;
}
.lb-btn {
  position: absolute;
  background: rgba(255,255,255,.12);
  border: 0;
  color: #fff;
  width: 46px; height: 46px;
  border-radius: 50%;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s;
}
.lb-btn:hover { background: rgba(255,255,255,.25); }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 18px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 18px; top: 50%; transform: translateY(-50%); }
.lb-count {
  position: absolute;
  bottom: 18px; left: 50%; transform: translateX(-50%);
  color: rgba(255,255,255,.75);
  font-size: .9rem;
  font-variant-numeric: tabular-nums;
}

/* ---------- Share buttons ---------- */
.share {
  margin-top: 2.4em;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}
.share-label {
  display: block;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 12px;
}
.share-row { display: flex; flex-wrap: wrap; gap: 9px; }
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: .5em;
  font: inherit;
  font-size: .9rem;
  font-weight: 600;
  padding: .5em 1em;
  border-radius: 8px;
  border: 1.5px solid var(--line);
  background: #fff;
  color: var(--ink-2);
  cursor: pointer;
  transition: border-color .15s, color .15s, background .15s;
}
.share-btn:hover {
  text-decoration: none;
  border-color: var(--red);
  color: var(--red);
  background: var(--red-tint);
}
.share-btn svg { width: 17px; height: 17px; stroke: currentColor; flex: none; }
.share-btn[data-copied] { border-color: var(--red); color: var(--red); }
@media (max-width: 420px) {
  .share-btn span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .share-btn { padding: .6em .8em; }
}

/* Visible spam check above the submit button. */
.spam-check {
  background: var(--red-tint);
  border: 1px solid #f6d9da;
  border-radius: 8px;
  padding: 16px 18px;
}
.spam-check label { margin-bottom: 2px; }
.spam-check input { max-width: 140px; }
.spam-check .form-note { margin-top: 2px; }

/* Honeypot: off-screen rather than display:none, which some bots detect. */
.hp-field {
  position: absolute !important;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: -999px; top: 8px;
  background: var(--red); color: #fff;
  padding: .6em 1.1em; border-radius: 6px; z-index: 100;
}
.skip-link:focus { left: 16px; }
