/* =========================================================================
   South Africa | Forbes Global Properties
   Magazine front page, aligned to the parent brand design language.
   White editorial. FreightNeo + Work Sans. Black, white, Forbes red.
   ========================================================================= */

@font-face { font-family: "FreightNeo"; src: url("assets/brand/FreightNeo-Light.woff2") format("woff2"); font-weight: 300; font-display: swap; }
@font-face { font-family: "FreightNeo"; src: url("assets/brand/FreightNeo-Book.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "FreightNeo"; src: url("assets/brand/FreightNeo-Semi.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Work Sans"; src: url("assets/brand/WorkSans-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Work Sans"; src: url("assets/brand/WorkSans-Medium.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Work Sans"; src: url("assets/brand/WorkSans-SemiBold.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --white: #ffffff;
  --black: #000000;
  --text: #333333;
  --soft: #6b6b6b;
  --line: #e3e0db;
  --rule: #000000;
  --red: #d8361e;          /* Forbes red, verified on the parent site */
  --gray-band: #f2f0ee;
  --display: "FreightNeo", Georgia, "Times New Roman", serif;
  --sans: "Work Sans", system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --maxw: 1360px;
  --pad: clamp(1.2rem, 4vw, 3.4rem);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--white); color: var(--text);
  font-family: var(--sans); font-size: 16px; line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 400; color: var(--black); margin: 0; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding-left: var(--pad); padding-right: var(--pad); }

/* ---------- Chips and buttons ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 0.55em;
  background: var(--black); color: var(--white);
  font-family: var(--sans); font-size: 12px; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  padding: 0.72em 1.25em; border: 0; border-radius: 3px; cursor: pointer;
  transition: background 0.3s var(--ease);
}
.chip:hover { background: var(--red); }
.chip--red { background: var(--red); }
.chip--red:hover { background: var(--black); }

/* ---------- Accessibility ---------- */
.skip-link {
  position: fixed; top: 0; left: 50%; transform: translate(-50%, -120%); z-index: 200;
  background: var(--black); color: var(--white); padding: 0.7rem 1.2rem; font-size: 13px;
  border-radius: 0 0 3px 3px; transition: transform 0.2s var(--ease);
}
.skip-link:focus { transform: translate(-50%, 0); outline: none; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }

/* ---------- Masthead ---------- */
.mast {
  position: sticky; top: 0; z-index: 60;
  background: var(--black); color: var(--white);
  border-bottom: 2px solid var(--red);
}
.mast__inner {
  max-width: var(--maxw); margin: 0 auto; padding: 0 var(--pad);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  min-height: 76px;
}
.mast__left { justify-self: start; display: flex; gap: 1.6rem; }
.mast__left a { font-size: 13px; letter-spacing: 0.05em; color: rgba(255,255,255,0.85); transition: color 0.3s; }
.mast__left a:hover { color: var(--white); }
.mast__brand { justify-self: center; text-align: center; font-family: var(--display); line-height: 1.15; }
.mast__brand strong { display: block; font-weight: 600; font-size: 1.3rem; letter-spacing: 0.02em; }
.mast__brand span { display: block; font-family: var(--sans); font-weight: 500; font-size: 9.5px; letter-spacing: 0.42em; text-transform: uppercase; margin-top: 2px; color: rgba(255,255,255,0.92); }
.mast__right { justify-self: end; }

/* ---------- Tagline bar ---------- */
.tagline { border-bottom: 2px solid var(--rule); }
.tagline p {
  max-width: var(--maxw); margin: 0 auto; padding: 1.05rem var(--pad);
  font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--black);
}

/* ---------- Front page: featured + rail ---------- */
.front { padding: clamp(1.8rem, 3.5vw, 3rem) 0 clamp(2.4rem, 4vw, 3.6rem); }
.front__grid { display: grid; grid-template-columns: 2fr 1fr; gap: clamp(1.6rem, 3vw, 3rem); }

.featured { display: block; }
.featured__media { position: relative; aspect-ratio: 3 / 2; overflow: hidden; background: var(--gray-band); }
.featured__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.featured:hover .featured__media img { transform: scale(1.025); }
.featured__media .chip { position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); }
.featured h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); line-height: 1.15; margin: 1.3rem 0 0.7rem; }
.featured p { margin: 0; color: var(--text); max-width: 68ch; }
.featured__meta { font-size: 14px; color: var(--soft); margin: 0.8rem 0 0; }

.rail { display: flex; flex-direction: column; gap: clamp(1.6rem, 3vw, 2.4rem); }
.rail__card { display: block; }
.rail__media { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: var(--gray-band); }
.rail__media img { width: 100%; height: 100%; object-fit: cover; }
.rail__media .chip { position: absolute; left: 0; bottom: 0; padding: 0.5em 0.9em; font-size: 10.5px; }
.rail__card h3 { font-size: clamp(1.25rem, 1.9vw, 1.6rem); line-height: 1.2; margin: 0.9rem 0 0; }
.rail__card:hover h3 { color: var(--red); }

/* ---------- Section header ---------- */
.secthead { border-top: 2px solid var(--rule); padding-top: 1rem; margin-bottom: clamp(1.6rem, 3vw, 2.4rem); display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.secthead h2 { font-size: clamp(1.6rem, 2.8vw, 2.2rem); }
.secthead h2 .arrow { font-family: var(--sans); font-weight: 300; margin-left: 0.45em; }
.secthead .secthead__note { font-size: 13px; color: var(--soft); }
section { padding: 0 0 clamp(2.8rem, 5vw, 4.4rem); }

/* ---------- Property cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.4rem, 2.6vw, 2.4rem); }
.card { display: block; }
.card__cat { font-family: var(--display); font-size: 1.35rem; color: var(--black); margin: 0 0 0.8rem; }
.card__media { aspect-ratio: 3 / 2; overflow: hidden; background: var(--gray-band); }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease); }
.card:hover .card__media img { transform: scale(1.03); }
.card__price { font-weight: 500; color: var(--black); margin: 0.9rem 0 0.15rem; font-size: 15px; }
.card__loc { font-size: 13.5px; color: var(--soft); margin: 0 0 0.35rem; }
.card__title { font-family: var(--display); font-size: 1.45rem; line-height: 1.2; color: var(--black); margin: 0; }
.card:hover .card__title { color: var(--red); }

/* type-led interim card, for regions awaiting photography */
.card--type { border: 1px solid var(--line); padding: clamp(1.4rem, 2.4vw, 2rem); display: flex; flex-direction: column; min-height: 100%; }
.card--type .card__k { font-family: var(--display); font-size: 1.2rem; color: var(--red); margin: 0 0 auto; }
.card--type h3 { font-size: 1.6rem; margin: 2.6rem 0 0.6rem; }
.card--type p { margin: 0 0 1.2rem; color: var(--text); }
.card--type .card__link { font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; font-weight: 500; color: var(--black); border-bottom: 2px solid var(--red); padding-bottom: 2px; align-self: flex-start; }

/* ---------- Stats strip ---------- */
.stats { border-top: 2px solid var(--rule); border-bottom: 1px solid var(--line); margin-bottom: clamp(2.8rem, 5vw, 4.4rem); }
.stats ul { list-style: none; margin: 0; padding: clamp(1.6rem, 3vw, 2.4rem) var(--pad); display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6rem; }
.stats li { display: flex; flex-direction: column; gap: 0.2rem; }
.stats__k { font-size: 11px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: var(--soft); }
.stats strong { font-family: var(--display); font-weight: 400; font-size: clamp(1.9rem, 3vw, 2.6rem); color: var(--black); }
.stats__d { font-size: 13px; color: var(--soft); line-height: 1.45; }

/* ---------- About / editorial ---------- */
.about__grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(1.8rem, 4vw, 4rem); align-items: start; }
.about__grid > div:first-child h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); line-height: 1.12; }
.about__grid p { margin: 0 0 1rem; max-width: 58ch; }
.about__note { border-top: 2px solid var(--rule); padding-top: 1rem; margin-top: 1.6rem; }
.about__note span { font-size: 11px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: var(--red); display: block; margin-bottom: 0.5rem; }
.about__note p { font-family: var(--display); font-size: 1.25rem; line-height: 1.4; color: var(--black); }

/* ---------- Services ---------- */
.services__grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: clamp(1.8rem, 4vw, 4rem); }
.services__intro p { margin: 0 0 1.4rem; max-width: 46ch; }
.services ol { list-style: none; margin: 0; padding: 0; }
.services li { display: grid; grid-template-columns: 3rem 1fr; gap: 0.9rem; align-items: baseline; padding: 1.05rem 0; border-top: 1px solid var(--line); font-family: var(--display); font-size: clamp(1.15rem, 1.9vw, 1.5rem); color: var(--black); }
.services li:last-child { border-bottom: 1px solid var(--line); }
.services li span { font-family: var(--sans); font-size: 12px; font-weight: 500; letter-spacing: 0.1em; color: var(--red); }

/* ---------- Stories ---------- */
.stories { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.4rem, 2.6vw, 2.4rem); }
.story { display: grid; grid-template-columns: 104px 1fr; gap: 1rem; align-items: start; }
.story img { aspect-ratio: 3 / 2; object-fit: cover; background: var(--gray-band); }
.story h3 { font-size: 1.15rem; line-height: 1.3; }
.story h3 em { font-style: normal; }
.story h3 .pipe { color: var(--red); margin: 0 0.3em; }
.story:hover h3 { color: var(--red); }
.story p { grid-column: 2; font-size: 13px; color: var(--soft); margin: 0.4rem 0 0; }

/* ---------- Private office ---------- */
.office { background: var(--gray-band); border-top: 2px solid var(--rule); padding: clamp(2.8rem, 5vw, 4.4rem) 0; margin-bottom: 0; }
.office__grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(1.8rem, 4vw, 4rem); align-items: start; }
.office h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); line-height: 1.12; margin-bottom: 1rem; }
.office__intro p { margin: 0 0 1rem; max-width: 46ch; }
.office__direct { font-size: 14px; color: var(--soft); }
.office__direct a { color: var(--black); border-bottom: 2px solid var(--red); font-weight: 500; }
.office form { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: 11px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; color: var(--soft); }
.field input, .field textarea {
  background: var(--white); border: 1px solid #c9c5bf; color: var(--black);
  padding: 0.8rem 0.85rem; font-family: var(--sans); font-size: 15px; border-radius: 2px; resize: vertical;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--black); }
.field input[aria-invalid="true"], .field textarea[aria-invalid="true"] { border-color: var(--red); }
.office form .chip { grid-column: 1 / -1; justify-self: start; }
.office__note { grid-column: 1 / -1; font-size: 14px; color: var(--black); min-height: 1.2em; margin: 0; }

/* ---------- Directory ---------- */
.directory { padding-top: clamp(2.4rem, 4.5vw, 3.6rem); }
.directory__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.8rem; }
.directory h4 { font-size: 1.15rem; margin: 0 0 0.8rem; }
.directory ul { list-style: none; margin: 0; padding: 0; }
.directory li { font-size: 13.5px; color: var(--soft); padding: 0.28rem 0; }

/* ---------- Footer ---------- */
.footer { background: var(--gray-band); border-top: 2px solid var(--rule); padding: clamp(2.4rem, 5vw, 4rem) 0 2rem; }
.footer__row { display: flex; align-items: center; justify-content: space-between; gap: 1.6rem; flex-wrap: wrap; padding-bottom: 1.4rem; border-bottom: 2px solid var(--rule); }
.footer__brand { font-family: var(--display); font-size: 1.15rem; color: var(--black); }
.footer__brand span { color: var(--red); margin: 0 0.3em; }
.footer__nav { display: flex; gap: clamp(1rem, 2.5vw, 2rem); flex-wrap: wrap; }
.footer__nav a { font-size: 13.5px; font-weight: 600; color: var(--black); }
.footer__nav a:hover { color: var(--red); }
.footer__legal { text-align: center; font-size: 12px; color: var(--soft); max-width: 72ch; margin: 1.8rem auto 0; line-height: 1.7; }
.footer__legal a { border-bottom: 1px solid var(--line); }

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
  .front__grid { grid-template-columns: 1fr; }
  .rail { flex-direction: row; }
  .rail__card { flex: 1; }
  .about__grid, .services__grid, .office__grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .mast__inner { grid-template-columns: auto 1fr; min-height: 64px; }
  .mast__left { display: none; }
  .mast__brand { justify-self: start; text-align: left; }
  .cards, .stories { grid-template-columns: 1fr; }
  .rail { flex-direction: column; }
  .stats ul { grid-template-columns: repeat(2, 1fr); }
  .directory__grid { grid-template-columns: repeat(2, 1fr); }
  .office form { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition-duration: 0.001ms !important; }
}
