/* =========================================================================
   THE OXFORDSHIRE PROPERTY AGENT — Homepage concept
   Editorial premium-property direction · navy / cream / terracotta
   Type: Libre Caslon Display (headlines) + Hanken Grotesk (body/UI)
   ========================================================================= */

/* ---------- Tokens ---------- */
:root {
  /* Brand palette (fixed) — values expressed in OKLCH, anchored to the
     brand hexes from the design brief. Shades lifted/deepened within the
     family only where contrast demands it. */
  --navy:            oklch(0.36 0.028 240);   /* #33414E */
  --navy-deep:       oklch(0.31 0.028 240);   /* #2B3742 */
  --navy-deeper:     oklch(0.26 0.026 242);   /* footer / proof */
  --cream:           oklch(0.94 0.018 80);    /* #F0EADF */
  --cream-hi:        oklch(0.965 0.013 82);   /* lighter surface */
  --cream-lo:        oklch(0.905 0.020 78);   /* subtle panel */

  --terracotta:      oklch(0.66 0.10 44);     /* #C57B5C — brand accent */
  --terracotta-btn:  oklch(0.575 0.108 40);   /* deeper — button fill, white text AA */
  --terracotta-ink:  oklch(0.515 0.115 40);   /* terracotta text on cream (AA) */
  --terracotta-glow: oklch(0.76 0.105 52);    /* lifted — accent text on navy (AA large) */
  --clay:            oklch(0.51 0.112 39);    /* deep terracotta drench — white text AA */

  --ink:             oklch(0.26 0.006 60);    /* body text on cream */
  --muted:           oklch(0.46 0.012 64);    /* secondary text on cream (AA) */
  --line:            oklch(0.36 0.02 70 / 0.18);

  /* Typography */
  --font-display: "Libre Caslon Display", "Libre Caslon Text", Georgia, "Times New Roman", serif;
  --font-body: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --step--1: clamp(0.82rem, 0.78rem + 0.18vw, 0.92rem);
  --step-0:  clamp(1rem, 0.96rem + 0.2vw, 1.12rem);
  --step-1:  clamp(1.2rem, 1.12rem + 0.4vw, 1.45rem);
  --step-2:  clamp(1.45rem, 1.3rem + 0.8vw, 2rem);
  --step-3:  clamp(1.9rem, 1.6rem + 1.5vw, 2.9rem);
  --step-4:  clamp(2.4rem, 1.9rem + 2.6vw, 3.9rem);
  --step-hero: clamp(2.85rem, 1.9rem + 4.6vw, 5.4rem);

  /* Space */
  --space-xs: 0.5rem;
  --space-sm: 0.875rem;
  --space-md: 1.5rem;
  --space-lg: clamp(2rem, 1.4rem + 2.4vw, 3.5rem);
  --space-xl: clamp(3.5rem, 2.4rem + 4.5vw, 7rem);
  --space-2xl: clamp(5rem, 3.4rem + 7vw, 10rem);

  --container: 76rem;
  --container-wide: 84rem;
  --radius: 4px;
  --radius-pill: 999px;

  /* Motion */
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-1: 0.45s;
  --dur-2: 0.7s;
  --dur-3: 1.1s;

  /* Z-scale (semantic) */
  --z-base: 0;
  --z-raised: 10;
  --z-sticky: 100;
  --z-nav: 200;
  --z-overlay: 300;
  --z-modal: 400;
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "kern", "liga", "calt";
  overflow-x: hidden;
}

img, picture, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; border: none; background: none; }
ul { list-style: none; padding: 0; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

::selection { background: var(--terracotta); color: #fff; }

:focus-visible {
  outline: 2.5px solid var(--terracotta-glow);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ---------- Layout helpers ---------- */
.container { width: min(100% - 2.5rem, var(--container)); margin-inline: auto; }
.container-wide { width: min(100% - 2.5rem, var(--container-wide)); margin-inline: auto; }

.eyebrow {
  font-family: var(--font-body);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--terracotta-ink);
}
.eyebrow--onDark { color: var(--terracotta-glow); }
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 1.8rem;
  height: 1px;
  background: currentColor;
  vertical-align: middle;
  margin-right: 0.7rem;
  opacity: 0.7;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 52px;
  padding: 0.85rem 1.6rem;
  font-family: var(--font-body);
  font-size: var(--step-0);
  font-weight: 600;
  letter-spacing: 0.005em;
  border-radius: var(--radius-pill);
  transition: transform var(--dur-1) var(--ease-out-quart),
              background-color var(--dur-1) var(--ease-out-quart),
              color var(--dur-1) var(--ease-out-quart),
              box-shadow var(--dur-1) var(--ease-out-quart);
  will-change: transform;
}
.btn:active { transform: translateY(1px); }

.btn--primary {
  background: var(--terracotta-btn);
  color: #fff;
  box-shadow: 0 1px 0 oklch(0.5 0.1 42 / 0.5), 0 10px 24px -12px oklch(0.5 0.1 42 / 0.9);
}
.btn--primary:hover { background: oklch(0.56 0.11 41); transform: translateY(-2px); box-shadow: 0 16px 30px -14px oklch(0.5 0.1 42 / 1); }

.btn--ghost {
  background: transparent;
  color: var(--cream);
  box-shadow: inset 0 0 0 1.5px oklch(0.94 0.018 80 / 0.55);
}
.btn--ghost:hover { background: oklch(0.94 0.018 80 / 0.1); box-shadow: inset 0 0 0 1.5px var(--cream); transform: translateY(-2px); }

.btn--ghost-dark {
  background: transparent;
  color: var(--navy);
  box-shadow: inset 0 0 0 1.5px oklch(0.36 0.028 240 / 0.4);
}
.btn--ghost-dark:hover { background: oklch(0.36 0.028 240 / 0.06); box-shadow: inset 0 0 0 1.5px var(--navy); transform: translateY(-2px); }

.btn--onTerra {
  background: var(--navy);
  color: var(--cream);
  box-shadow: 0 12px 26px -14px oklch(0.2 0.02 240 / 1);
}
.btn--onTerra:hover { background: var(--navy-deep); transform: translateY(-2px); }

.textlink {
  font-weight: 600;
  color: var(--terracotta-ink);
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: gap var(--dur-1) var(--ease-out-quart);
}
.textlink .arr { transition: transform var(--dur-1) var(--ease-out-quart); }
.textlink:hover .arr { transform: translateX(4px); }

/* =========================================================================
   HEADER
   ========================================================================= */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: var(--z-nav);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding: 1.1rem clamp(1.25rem, 4vw, 3rem);
  color: var(--cream);
  transition: background-color var(--dur-2) var(--ease-out-quart),
              padding var(--dur-2) var(--ease-out-quart),
              box-shadow var(--dur-2) var(--ease-out-quart),
              color var(--dur-2) var(--ease-out-quart);
}
/* legibility scrim over hero imagery before scroll */
.site-header::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 170px;
  background: linear-gradient(to bottom, oklch(0.22 0.024 242 / 0.82), oklch(0.22 0.024 242 / 0.35) 45%, transparent);
  z-index: -1; pointer-events: none;
  transition: opacity var(--dur-2) var(--ease-out-quart);
}
.site-header.is-scrolled {
  background: oklch(0.31 0.028 240 / 0.92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding-block: 0.7rem;
  box-shadow: 0 1px 0 oklch(0.94 0.018 80 / 0.08), 0 14px 40px -28px #000;
}
.site-header.is-scrolled::before { opacity: 0; }

/* Wordmark — typographic reconstruction of the existing lockup.
   Replace with the official logo SVG before production. */
.wordmark { display: inline-flex; align-items: center; line-height: 0; }
/* real logo SVG (cream + terracotta, for dark backgrounds) */
.wordmark__img { height: 62px; width: auto; display: block; transition: height var(--dur-2) var(--ease-out-quart); }
.site-header.is-scrolled .wordmark__img { height: 54px; }
/* keep the mobile header from being dominated by the taller logo */
@media (max-width: 52rem) {
  .wordmark__img { height: 48px; }
  .site-header.is-scrolled .wordmark__img { height: 44px; }
}
.wordmark__top {
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 0.58rem; letter-spacing: 0.42em; text-transform: uppercase;
  font-weight: 600; padding-left: 0.42em;
}
.wordmark__top::before, .wordmark__top::after {
  content: ""; width: 1.5rem; height: 1px; background: currentColor; opacity: 0.65;
}
.wordmark__name {
  font-family: var(--font-display);
  font-size: 1.32rem; letter-spacing: 0.2em; padding-left: 0.2em; font-weight: 400;
}

.nav { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.2rem); }
.nav__links { display: flex; gap: clamp(1rem, 2vw, 1.9rem); }
.nav__links a {
  font-size: var(--step--1);
  font-weight: 500;
  letter-spacing: 0.04em;
  position: relative;
  padding-block: 0.3rem;
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; bottom: 0; width: 0; height: 1.5px;
  background: var(--terracotta-glow); transition: width var(--dur-1) var(--ease-out-quart);
}
.nav__links a:hover::after, .nav__links a:focus-visible::after { width: 100%; }

.nav__cta { padding-block: 0.6rem; min-height: 44px; }

.nav__toggle { display: none; width: 44px; height: 44px; align-items: center; justify-content: center; }
.nav__toggle span, .nav__toggle span::before, .nav__toggle span::after {
  content: ""; display: block; width: 22px; height: 1.6px; background: currentColor;
  position: relative; transition: transform var(--dur-1) var(--ease-out-quart), opacity var(--dur-1);
}
.nav__toggle span::before { position: absolute; top: -6.5px; }
.nav__toggle span::after { position: absolute; top: 6.5px; }

/* =========================================================================
   HERO
   ========================================================================= */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  background: var(--navy);
  color: var(--cream);
  isolation: isolate;
  overflow: hidden;
}
.hero__content {
  display: flex; flex-direction: column; justify-content: center;
  gap: var(--space-md);
  padding: clamp(7rem, 12vh, 11rem) clamp(1.5rem, 4vw, 4rem) var(--space-xl) clamp(1.5rem, 6vw, 6rem);
  max-width: 40rem;
  z-index: var(--z-raised);
}
.hero__title {
  font-size: var(--step-hero);
  letter-spacing: -0.022em;
  line-height: 0.98;
}
.hero__title .accent { color: var(--terracotta-glow); font-style: italic; }
.hero__title s { text-decoration-line: line-through; text-decoration-thickness: 0.055em; text-decoration-color: var(--terracotta-glow); color: oklch(0.94 0.018 80 / 0.5); }
.hero__lede {
  font-size: var(--step-1);
  line-height: 1.5;
  color: oklch(0.94 0.018 80 / 0.82);
  max-width: 34ch;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: var(--space-xs); }
.hero__trust {
  display: flex; align-items: center; gap: 0.65rem;
  font-size: var(--step--1); color: oklch(0.94 0.018 80 / 0.72); margin-top: var(--space-sm);
}
.hero__stars { color: var(--terracotta-glow); letter-spacing: 0.1em; font-size: 0.95rem; }
.hero__trust strong { color: var(--cream); font-weight: 600; }

.hero__media { position: relative; z-index: var(--z-base); overflow: hidden; }
.hero__media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  object-position: center 40%;
}
/* navy feather blending the image into the type column */
.hero__media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, var(--navy) 0%, oklch(0.36 0.028 240 / 0.55) 22%, transparent 55%),
    linear-gradient(0deg, oklch(0.31 0.028 240 / 0.5), transparent 40%);
}
.hero__scroll {
  position: absolute; left: clamp(1.5rem, 6vw, 6rem); bottom: 1.8rem;
  display: inline-flex; align-items: center; gap: 0.6rem; z-index: var(--z-raised);
  font-size: 0.72rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: oklch(0.94 0.018 80 / 0.6);
}
.hero__scroll .dot { width: 1px; height: 34px; background: linear-gradient(var(--terracotta-glow), transparent); }

/* =========================================================================
   FEATURED PROPERTIES
   ========================================================================= */
.section { padding-block: var(--space-2xl); }
.section--cream { background: var(--cream); color: var(--ink); }
.section--navy { background: var(--navy); color: var(--cream); }

.section-head { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: var(--space-md); margin-bottom: var(--space-lg); }
.section-head__title { font-size: var(--step-4); max-width: 18ch; }
.section--navy .section-head__title { color: var(--cream); }
.section-head__aside { max-width: 34ch; color: var(--muted); font-size: var(--step-0); }
.section--navy .section-head__aside { color: oklch(0.94 0.018 80 / 0.7); }

.properties { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 2vw, 1.75rem); }
.property { display: flex; flex-direction: column; }
.property__media { position: relative; overflow: hidden; border-radius: var(--radius); aspect-ratio: 4 / 5; background: var(--cream-lo); }
.property__media img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-3) var(--ease-out-expo); }
.property:hover .property__media img { transform: scale(1.05); }
.property__tag {
  position: absolute; top: 0.85rem; left: 0.85rem;
  background: oklch(0.31 0.028 240 / 0.82); color: var(--cream);
  font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600;
  padding: 0.4rem 0.7rem; border-radius: var(--radius-pill);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
.property__body { padding-top: 1.05rem; display: flex; flex-direction: column; gap: 0.3rem; }
.property__price { font-family: var(--font-display); font-size: var(--step-2); letter-spacing: -0.01em; }
.property__place { font-weight: 600; font-size: var(--step-0); }
.property__meta { color: var(--muted); font-size: var(--step--1); display: flex; gap: 0.9rem; margin-top: 0.15rem; }
.property__meta span { display: inline-flex; align-items: center; gap: 0.35rem; }
.section-foot { margin-top: var(--space-lg); display: flex; justify-content: center; }

/* =========================================================================
   PROOF — editorial sentence, not the big-number template
   ========================================================================= */
.proof { background: var(--navy-deeper); color: var(--cream); padding-block: var(--space-xl); }
.proof__inner { display: grid; gap: var(--space-lg); }
.proof__lead { font-size: var(--step--1); letter-spacing: 0.2em; text-transform: uppercase; color: var(--terracotta-glow); font-weight: 600; }
.proof__sentence {
  font-family: var(--font-display);
  font-size: var(--step-3);
  line-height: 1.28;
  letter-spacing: -0.01em;
  max-width: 24ch;
  color: oklch(0.94 0.018 80 / 0.78);
}
.proof__sentence b { color: var(--cream); font-weight: 400; }
.proof__sentence .fig { color: var(--terracotta-glow); font-style: italic; }
.proof__figs { display: flex; flex-wrap: wrap; gap: clamp(1.5rem, 5vw, 4rem); border-top: 1px solid oklch(0.94 0.018 80 / 0.14); padding-top: var(--space-lg); }
.proof__fig { display: flex; flex-direction: column; gap: 0.25rem; }
.proof__fig dt { order: 2; font-size: var(--step--1); color: oklch(0.94 0.018 80 / 0.6); letter-spacing: 0.04em; }
.proof__fig dd { order: 1; font-family: var(--font-display); font-size: var(--step-2); color: var(--cream); }
@media (min-width: 60rem) {
  .proof__inner { grid-template-columns: 1.1fr 1fr; align-items: center; }
  .proof__figs { border-top: none; border-left: 1px solid oklch(0.94 0.018 80 / 0.14); padding-top: 0; padding-left: clamp(1.5rem, 4vw, 3.5rem); flex-direction: column; gap: var(--space-md); }
}

/* =========================================================================
   WHY US — rule-divided columns (no card grid, no numbered scaffold)
   ========================================================================= */
.why__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin-top: var(--space-lg); }
.why__col { padding: var(--space-md) clamp(1.2rem, 3vw, 2.4rem); border-left: 1px solid var(--line); }
.why__col:first-child { padding-left: 0; border-left: none; }
.why__mark { width: 2rem; height: 1px; background: var(--terracotta); margin-bottom: 1.1rem; }
.why__col h3 { font-size: var(--step-2); margin-bottom: 0.6rem; }
.why__col p { color: var(--muted); max-width: 32ch; }

/* =========================================================================
   AREA BAND — full-bleed scenery
   ========================================================================= */
.area {
  position: relative;
  min-height: clamp(28rem, 72vh, 44rem);
  display: grid; align-items: center;
  color: var(--cream);
  overflow: hidden;
  isolation: isolate;
}
.area__bg { position: absolute; inset: 0; z-index: -2; }
.area__bg img { width: 100%; height: 120%; object-fit: cover; will-change: transform; }
.area::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, oklch(0.26 0.026 242 / 0.85) 0%, oklch(0.31 0.028 240 / 0.5) 45%, oklch(0.31 0.028 240 / 0.2) 100%),
    linear-gradient(0deg, oklch(0.26 0.026 242 / 0.6), transparent 55%);
}
.area__content { padding: var(--space-xl) 0; max-width: 38rem; }
.area__title { font-size: var(--step-4); margin: var(--space-sm) 0 var(--space-md); }
.area__title .accent { color: var(--terracotta-glow); font-style: italic; }
.area__text { font-size: var(--step-1); color: oklch(0.94 0.018 80 / 0.85); max-width: 40ch; line-height: 1.5; }
.area__places {
  display: flex; flex-wrap: wrap; gap: 0.55rem 0.9rem; margin-top: var(--space-lg);
  font-size: var(--step--1); letter-spacing: 0.02em;
}
.area__places li {
  padding: 0.4rem 0.95rem; border: 1px solid oklch(0.94 0.018 80 / 0.3); border-radius: var(--radius-pill);
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
}

/* =========================================================================
   TESTIMONIAL
   ========================================================================= */
.quote { background: var(--cream); padding-block: var(--space-2xl); }
.quote__inner { max-width: 50rem; margin-inline: auto; text-align: center; }
.quote__mark { font-family: var(--font-display); font-size: 5rem; line-height: 0.6; color: var(--terracotta); height: 2.4rem; }
.quote blockquote { font-family: var(--font-display); font-size: var(--step-3); line-height: 1.3; letter-spacing: -0.01em; color: var(--ink); margin-block: var(--space-md); text-wrap: balance; }
.quote figcaption { font-size: var(--step--1); letter-spacing: 0.14em; text-transform: uppercase; color: var(--terracotta-ink); font-weight: 600; }
.quote figcaption span { color: var(--muted); }

/* =========================================================================
   FINAL CTA — terracotta drench
   ========================================================================= */
.cta-final { background: var(--clay); color: #fff; padding-block: var(--space-2xl); position: relative; overflow: hidden; }
.cta-final::before {
  content: ""; position: absolute; inset: 0; z-index: 0; opacity: 0.55;
  background: radial-gradient(130% 95% at 88% -10%, oklch(0.66 0.10 48 / 0.55), transparent 62%);
}
.cta-final__inner { position: relative; z-index: 1; display: grid; gap: var(--space-md); justify-items: start; max-width: 44rem; }
.cta-final h2 { font-size: var(--step-4); color: #fff; }
.cta-final p { font-size: var(--step-1); color: oklch(1 0 0 / 0.9); max-width: 40ch; }
.cta-final__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1.1rem; margin-top: var(--space-xs); }
.cta-final__actions .textlink { color: #fff; }

/* =========================================================================
   FOOTER
   ========================================================================= */
.footer { background: var(--navy-deeper); color: oklch(0.94 0.018 80 / 0.72); padding-block: var(--space-xl) var(--space-lg); }
.footer__top { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: var(--space-lg); padding-bottom: var(--space-lg); border-bottom: 1px solid oklch(0.94 0.018 80 / 0.12); }
.footer__brand .wordmark { align-items: flex-start; color: var(--cream); }
.footer__brand .wordmark__img { height: 58px; }
.footer__brand .wordmark__top { padding-left: 0; }
.footer__brand .wordmark__top::before { display: none; }
.footer__blurb { margin-top: var(--space-md); max-width: 30ch; font-size: var(--step--1); line-height: 1.6; }
.footer h4 { font-family: var(--font-body); font-size: var(--step--1); letter-spacing: 0.14em; text-transform: uppercase; color: var(--cream); font-weight: 600; margin-bottom: var(--space-sm); }
.footer__col a, .footer__col li { display: block; padding-block: 0.32rem; font-size: var(--step--1); transition: color var(--dur-1); }
.footer__col a:hover { color: var(--terracotta-glow); }
.footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-sm); padding-top: var(--space-lg); font-size: 0.78rem; color: oklch(0.94 0.018 80 / 0.5); }
.footer__bottom nav { display: flex; gap: var(--space-md); flex-wrap: wrap; }

/* =========================================================================
   MOTION — reveal on scroll (progressive: visible by default)
   ========================================================================= */
.js [data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity var(--dur-2) var(--ease-out-quart), transform var(--dur-2) var(--ease-out-quart); }
.js [data-reveal].is-visible { opacity: 1; transform: none; }
.js [data-reveal][data-reveal-delay="1"] { transition-delay: 0.08s; }
.js [data-reveal][data-reveal-delay="2"] { transition-delay: 0.16s; }
.js [data-reveal][data-reveal-delay="3"] { transition-delay: 0.24s; }
.js [data-reveal][data-reveal-delay="4"] { transition-delay: 0.32s; }

/* Hero load choreography */
.js .hero__content > * { opacity: 0; transform: translateY(26px); }
.js .hero.is-ready .hero__content > * { animation: heroIn var(--dur-3) var(--ease-out-expo) forwards; }
.js .hero.is-ready .hero__content > *:nth-child(1) { animation-delay: 0.15s; }
.js .hero.is-ready .hero__content > *:nth-child(2) { animation-delay: 0.28s; }
.js .hero.is-ready .hero__content > *:nth-child(3) { animation-delay: 0.42s; }
.js .hero.is-ready .hero__content > *:nth-child(4) { animation-delay: 0.54s; }
.js .hero.is-ready .hero__content > *:nth-child(5) { animation-delay: 0.66s; }
@keyframes heroIn { to { opacity: 1; transform: none; } }

.js .hero__media img { transform: scale(1.08); transition: transform 1.6s var(--ease-out-expo); }
.js .hero.is-ready .hero__media img { transform: scale(1); }

/* =========================================================================
   RESPONSIVE
   ========================================================================= */
@media (max-width: 64rem) {
  .properties { grid-template-columns: 1fr 1fr; }
  .footer__top { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 52rem) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero__content { order: 2; padding: var(--space-xl) clamp(1.5rem, 7vw, 3rem) var(--space-2xl); max-width: none; }
  .hero__media { order: 1; position: relative; height: 58svh; min-height: 22rem; }
  .hero__media::after { background: linear-gradient(0deg, var(--navy) 2%, oklch(0.36 0.028 240 / 0.25) 45%, transparent 75%); }
  .hero__scroll { display: none; }

  .nav__links, .nav__cta { display: none; }
  .nav__toggle { display: inline-flex; }

  /* mobile menu panel */
  .site-header.menu-open { background: var(--navy-deep); }
  .mobile-menu { position: fixed; inset: 0; z-index: var(--z-overlay); background: var(--navy-deep); color: var(--cream);
    display: grid; align-content: center; gap: var(--space-md); padding: var(--space-2xl) clamp(1.5rem, 8vw, 4rem);
    transform: translateY(-100%); transition: transform var(--dur-2) var(--ease-out-expo); visibility: hidden; }
  .mobile-menu.is-open { transform: none; visibility: visible; }
  .mobile-menu a { font-family: var(--font-display); font-size: var(--step-3); }
  .mobile-menu .btn { margin-top: var(--space-md); font-family: var(--font-body); }
  .mobile-menu__close { position: absolute; top: 1.4rem; right: 1.4rem; width: 48px; height: 48px; font-size: 1.6rem; }
}
@media (min-width: 52.0625rem) { .mobile-menu { display: none; } }

@media (max-width: 40rem) {
  .properties { grid-template-columns: 1fr; }
  .why__grid { grid-template-columns: 1fr; }
  .why__col { padding: var(--space-md) 0; border-left: none; border-top: 1px solid var(--line); }
  .why__col:first-child { border-top: none; padding-top: 0; }
  .footer__top { grid-template-columns: 1fr; gap: var(--space-md); }
  .section-head { flex-direction: column; align-items: flex-start; }
}

/* =========================================================================
   WHATSAPP CHAT WIDGET — bespoke, on-brand (not the stock green plugin)
   ========================================================================= */
.wa { position: fixed; right: clamp(1rem, 3vw, 2rem); bottom: clamp(1rem, 3vw, 2rem); z-index: 250; display: flex; flex-direction: column; align-items: flex-end; }

.wa__fab {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  width: 58px; height: 58px; border-radius: 50%;
  background: var(--navy); color: var(--cream); cursor: pointer;
  box-shadow: 0 14px 32px -12px oklch(0.2 0.02 240 / 0.75), inset 0 0 0 1px oklch(0.94 0.018 80 / 0.14);
  transition: transform var(--dur-1) var(--ease-out-quart), background-color var(--dur-1) var(--ease-out-quart);
}
.wa__fab svg { width: 29px; height: 29px; }
.wa__fab:hover { transform: translateY(-3px); background: var(--navy-deep); }
.wa__fab::after { content: ""; position: absolute; top: 7px; right: 7px; width: 11px; height: 11px; border-radius: 50%; background: #3fbf6b; box-shadow: 0 0 0 2px var(--navy); }
.wa.is-open .wa__fab::after { display: none; }

.wa__panel {
  position: absolute; bottom: calc(100% + 0.85rem); right: 0;
  width: min(320px, calc(100vw - 2rem));
  background: var(--cream-hi); border-radius: 14px; overflow: hidden;
  box-shadow: 0 28px 66px -22px oklch(0.18 0.02 240 / 0.85);
  transform: translateY(14px) scale(0.97); transform-origin: bottom right;
  opacity: 0; visibility: hidden;
  transition: opacity var(--dur-1) var(--ease-out-quart), transform var(--dur-1) var(--ease-out-quart), visibility var(--dur-1);
}
.wa__panel.is-open { opacity: 1; visibility: visible; transform: none; }
.wa__head { background: var(--navy); color: var(--cream); padding: 1rem 2.6rem 1rem 1.05rem; display: flex; align-items: center; gap: 0.7rem; position: relative; }
.wa__avatar { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 50%; background: var(--terracotta-btn); display: inline-flex; align-items: center; justify-content: center; color: #fff; }
.wa__avatar svg { width: 22px; height: 22px; }
.wa__name { font-weight: 600; font-size: var(--step-0); line-height: 1.2; color: var(--cream); }
.wa__status { font-size: var(--step--1); color: oklch(0.94 0.018 80 / 0.74); display: flex; align-items: center; gap: 0.4rem; margin-top: 0.15rem; }
.wa__status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #3fbf6b; }
.wa__close { position: absolute; top: 0.5rem; right: 0.55rem; width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; color: oklch(0.94 0.018 80 / 0.8); font-size: 1.4rem; line-height: 1; border-radius: 8px; }
.wa__close:hover { color: var(--cream); background: oklch(0.94 0.018 80 / 0.12); }
.wa__body { padding: 1.05rem; }
.wa__msg { background: #fff; border-radius: 4px 14px 14px 14px; padding: 0.85rem 1rem; font-size: var(--step-0); line-height: 1.5; color: var(--ink); box-shadow: 0 1px 3px oklch(0.2 0.02 240 / 0.1); }
.wa__cta { display: flex; align-items: center; justify-content: center; gap: 0.55rem; margin: 0 1.05rem 1.05rem; min-height: 48px; padding: 0.8rem 1rem; background: var(--terracotta-btn); color: #fff; border-radius: var(--radius-pill); font-weight: 600; transition: background-color var(--dur-1) var(--ease-out-quart), transform var(--dur-1) var(--ease-out-quart); }
.wa__cta:hover { background: oklch(0.56 0.11 41); transform: translateY(-1px); }
.wa__cta svg { width: 20px; height: 20px; }
@media (max-width: 32rem) { .wa__fab { width: 52px; height: 52px; } .wa__fab svg { width: 26px; height: 26px; } }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
  .js [data-reveal] { opacity: 1; transform: none; }
  .js .hero__content > * { opacity: 1; transform: none; }
  .js .hero__media img { transform: none; }
  .property:hover .property__media img { transform: none; }
}
