/* ============================================================
   Vuka Africa Ribane Housing Developments — public site
   Design system by Vertex Automations
   ============================================================ */

/* ---------- Design tokens ---------- */
:root {
  /* Palette — derived from logo, elevated */
  --ink:         #0B1B3F;          /* deep navy, primary */
  --ink-soft:    #1A2A52;
  --ink-line:    rgba(11,27,63,.14);
  --terracotta:  #C85A2A;          /* warm accent, from logo orange but richer */
  --terracotta-deep: #A54619;
  --terracotta-light: #E8A578;
  --ivory:       #F7F2EA;          /* warm background */
  --ivory-deep:  #EFE8DC;
  --paper:       #FBF8F2;
  --stone:       #8C8579;          /* muted */
  --stone-soft:  #B8B0A1;
  --charcoal:    #1B1D22;          /* body text */
  --charcoal-soft: #3A3D45;
  --white:       #FFFFFF;
  --green-ok:    #2B6A4A;
  --red-warn:    #A93226;

  /* Type */
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body:    'Instrument Sans', -apple-system, system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', 'SF Mono', Consolas, monospace;

  /* Scale — fluid type */
  --step--2: clamp(0.75rem, 0.72rem + 0.15vw, 0.82rem);
  --step--1: clamp(0.85rem, 0.82rem + 0.18vw, 0.94rem);
  --step-0:  clamp(0.95rem, 0.92rem + 0.2vw, 1.05rem);
  --step-1:  clamp(1.1rem, 1.05rem + 0.3vw, 1.25rem);
  --step-2:  clamp(1.35rem, 1.25rem + 0.6vw, 1.65rem);
  --step-3:  clamp(1.7rem, 1.5rem + 1vw, 2.15rem);
  --step-4:  clamp(2.2rem, 1.85rem + 1.8vw, 3rem);
  --step-5:  clamp(2.9rem, 2.3rem + 3vw, 4.5rem);
  --step-6:  clamp(3.8rem, 2.8rem + 5vw, 6.5rem);
  --step-7:  clamp(5rem, 3.5rem + 7.5vw, 9rem);

  /* Space */
  --sp-1: 0.35rem;
  --sp-2: 0.7rem;
  --sp-3: 1.1rem;
  --sp-4: 1.6rem;
  --sp-5: 2.4rem;
  --sp-6: 3.5rem;
  --sp-7: 5rem;
  --sp-8: 7rem;
  --sp-9: 9rem;

  /* Radii */
  --r-sm: 4px;
  --r-md: 10px;
  --r-lg: 18px;

  /* Layout */
  --container: 1320px;
  --container-narrow: 880px;
  --gutter: clamp(1.25rem, 3vw, 2.5rem);
  --header-h: 84px;

  /* Motion */
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

/* ---------- Reset-ish base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.55;
  color: var(--charcoal);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: var(--ink); text-decoration: none; transition: color .2s var(--ease-out); }
a:hover { color: var(--terracotta); }

button { font-family: inherit; cursor: pointer; border: 0; background: transparent; color: inherit; }
input, textarea, select, button { font-family: inherit; font-size: inherit; }

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

.skip-link {
  position: absolute; left: -9999px; top: 0; background: var(--ink); color: var(--ivory);
  padding: 0.75rem 1.25rem; z-index: 999; text-decoration: none;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* ---------- Typography ---------- */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 400;
  font-style: normal;
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 0 0 var(--sp-3);
  font-variation-settings: "opsz" 144, "SOFT" 50;
}
h1 { font-size: var(--step-6); font-weight: 300; letter-spacing: -0.025em; }
h2 { font-size: var(--step-5); font-weight: 350; letter-spacing: -0.02em; }
h3 { font-size: var(--step-4); font-weight: 400; }
h4 { font-size: var(--step-3); font-weight: 400; }
h5 { font-size: var(--step-1); font-weight: 500; }

p { margin: 0 0 var(--sp-3); }
.lede { font-size: var(--step-2); line-height: 1.4; color: var(--charcoal-soft); font-weight: 300; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--step--1);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--terracotta);
  display: inline-flex;
  align-items: center;
  gap: 0.8em;
}
.eyebrow::before {
  content: '';
  width: 28px;
  height: 1px;
  background: var(--terracotta);
  display: inline-block;
}

.display-italic { font-style: italic; font-variation-settings: "opsz" 144, "SOFT" 100; color: var(--terracotta-deep); }

.muted { color: var(--stone); }
.small { font-size: var(--step--1); }
.tnum { font-variant-numeric: tabular-nums; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.container--narrow { max-width: var(--container-narrow); }
.section { padding: var(--sp-8) 0; }
.section--tight { padding: var(--sp-7) 0; }
.section--hero { padding: 0; }
.section--dark { background: var(--ink); color: var(--ivory); }
.section--dark h1, .section--dark h2, .section--dark h3, .section--dark h4, .section--dark h5 { color: var(--ivory); }
.section--paper { background: var(--paper); }
.section--ivory-deep { background: var(--ivory-deep); }

.grid { display: grid; gap: var(--sp-5); }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 720px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  padding: 1rem 1.8rem;
  font-family: var(--font-body);
  font-size: var(--step-0);
  font-weight: 500;
  letter-spacing: 0.02em;
  border-radius: 2px;
  text-decoration: none;
  transition: all .25s var(--ease-out);
  cursor: pointer;
  border: 1px solid transparent;
  line-height: 1;
  white-space: nowrap;
}
.btn--primary {
  background: var(--ink);
  color: var(--ivory);
}
.btn--primary:hover { background: var(--terracotta); color: var(--ivory); }
.btn--outline {
  border-color: var(--ink);
  color: var(--ink);
  background: transparent;
}
.btn--outline:hover { background: var(--ink); color: var(--ivory); }
.btn--ghost-light {
  border-color: rgba(247,242,234,.4);
  color: var(--ivory);
  background: transparent;
}
.btn--ghost-light:hover { background: var(--ivory); color: var(--ink); }
.btn--terracotta { background: var(--terracotta); color: var(--ivory); }
.btn--terracotta:hover { background: var(--terracotta-deep); }
.btn--sm { padding: 0.65rem 1.2rem; font-size: var(--step--1); }
.btn--lg { padding: 1.2rem 2.2rem; font-size: var(--step-1); }
.btn--block { width: 100%; justify-content: center; }

/* Link with arrow */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-weight: 500;
  font-size: var(--step-0);
  color: var(--ink);
  position: relative;
  padding-bottom: 0.2em;
}
.link-arrow::after {
  content: '→';
  transition: transform .3s var(--ease-out);
}
.link-arrow:hover::after { transform: translateX(6px); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 242, 234, 0.85);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--ink-line);
  transition: background .3s var(--ease-out);
}
.site-header.is-scrolled {
  background: rgba(247, 242, 234, 0.95);
}
.site-header__bar {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
}
.site-header__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--ink);
}
.site-header__brand img { height: 44px; width: auto; }
.site-header__wordmark { display: flex; flex-direction: column; line-height: 1; }
.site-header__wordmark-top {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin-bottom: 3px;
}
.site-header__wordmark-main {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 500;
  font-style: italic;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.site-nav { display: none; }
@media (min-width: 1180px) { .site-nav { display: block; } }
.site-nav__list { list-style: none; margin: 0; padding: 0; display: flex; gap: 1.5rem; }
.site-nav__list a {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  position: relative;
  padding: 0.4rem 0;
  transition: color .2s;
  white-space: nowrap;
}
.site-nav__list a::after {
  content: '';
  position: absolute;
  left: 0; right: 100%;
  bottom: 0;
  height: 1px;
  background: var(--terracotta);
  transition: right .3s var(--ease-out);
}
.site-nav__list a:hover, .site-nav__list a.is-active { color: var(--terracotta); }
.site-nav__list a:hover::after, .site-nav__list a.is-active::after { right: 0; }

.site-header__actions { display: flex; align-items: center; gap: var(--sp-3); }
.site-header__menu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
}
@media (min-width: 1180px) { .site-header__menu-toggle { display: none; } }
.menu-icon { display: inline-flex; flex-direction: column; gap: 4px; width: 22px; }
.menu-icon span { width: 22px; height: 2px; background: var(--ink); transition: all .3s var(--ease-out); transform-origin: center; }
[aria-expanded="true"] .menu-icon span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
[aria-expanded="true"] .menu-icon span:nth-child(2) { opacity: 0; }
[aria-expanded="true"] .menu-icon span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Mobile drawer ---------- */
.mobile-drawer {
  position: fixed;
  inset: 0;
  background: var(--ink);
  color: var(--ivory);
  z-index: 45;
  opacity: 0;
  visibility: hidden;
  transition: opacity .35s var(--ease-out), visibility 0s linear .35s;
  overflow-y: auto;
}
.mobile-drawer.is-open {
  opacity: 1;
  visibility: visible;
  transition: opacity .35s var(--ease-out);
}
.mobile-drawer__inner {
  padding: calc(var(--header-h) + 2rem) var(--gutter) var(--sp-5);
  min-height: 100%;
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
}
.mobile-drawer__head { display: flex; justify-content: space-between; align-items: center; }
.mobile-drawer__label {
  font-family: var(--font-mono);
  font-size: var(--step--1);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--terracotta-light);
}
.mobile-drawer__close {
  font-size: 2rem;
  line-height: 1;
  color: var(--ivory);
  width: 44px;
  height: 44px;
}
.mobile-drawer__nav ol { list-style: none; padding: 0; margin: 0 0 var(--sp-5); }
.mobile-drawer__nav li { border-top: 1px solid rgba(247,242,234,0.1); }
.mobile-drawer__nav li:last-child { border-bottom: 1px solid rgba(247,242,234,0.1); }
.mobile-drawer__nav a {
  display: flex;
  align-items: baseline;
  gap: var(--sp-3);
  padding: var(--sp-3) 0;
  color: var(--ivory);
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-weight: 300;
}
.mobile-drawer__nav .idx {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--terracotta-light);
}
.mobile-drawer__foot p { margin: 0.4rem 0; font-size: var(--step--1); }
.mobile-drawer__foot a { color: var(--ivory); }
.mobile-drawer__foot .muted { color: var(--stone-soft); }
body.drawer-open { overflow: hidden; }

/* ---------- Hero — Majeli-style centered composition ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--ink);
  color: var(--ivory);
  margin-top: calc(-1 * var(--header-h));
  padding: calc(var(--header-h) + var(--sp-4)) var(--gutter) var(--sp-6);
  text-align: center;
}
.hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}
.hero__media video,
.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  position: absolute;
  inset: 0;
}
/* Subtle slow Ken Burns breathing effect on the video */
.hero__video {
  animation: heroBreathe 22s ease-in-out infinite alternate;
}
@keyframes heroBreathe {
  0%   { transform: scale(1); }
  100% { transform: scale(1.04); }
}

/* Poster layer — sits on top of the video, holds for 3s, then fades to reveal video.
   This avoids the jarring "split-second poster, then video" default behavior. */
.hero__poster {
  z-index: 1;
  opacity: 1;
  /* Hold visible for 3s (delay), then fade out over 1.2s */
  animation: heroPosterFade 1.2s 3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  /* Same slow zoom as video so the transition feels continuous */
  animation-name: heroPosterFade, heroBreathe;
  animation-duration: 1.2s, 22s;
  animation-delay: 3s, 0s;
  animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1), ease-in-out;
  animation-fill-mode: forwards, forwards;
  animation-iteration-count: 1, infinite;
  animation-direction: normal, alternate;
}
@keyframes heroPosterFade {
  0%   { opacity: 1; }
  100% { opacity: 0; visibility: hidden; }
}
/* When there's no video, the poster stays visible (static) */
.hero__poster--static {
  animation: none;
  opacity: 1;
}

/* Respect reduced-motion: keep poster visible, don't animate */
@media (prefers-reduced-motion: reduce) {
  .hero__poster {
    animation: heroPosterFade 1.2s 3s linear forwards;
  }
  .hero__video { animation: none; }
}

.hero__veil {
  position: absolute;
  inset: 0;
  /* Darker around centre where text sits — video stays alive at edges, text stays crisp */
  background:
    radial-gradient(ellipse 80% 70% at 50% 50%, rgba(6,16,42,0.55) 0%, rgba(6,16,42,0.15) 60%, rgba(6,16,42,0) 100%),
    linear-gradient(180deg,
      rgba(6,16,42,0.55) 0%,
      rgba(6,16,42,0.2) 25%,
      rgba(6,16,42,0.3) 65%,
      rgba(6,16,42,0.8) 100%);
  z-index: 1;
}

.hero__center {
  position: relative;
  z-index: 2;
  max-width: 1100px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-3);
}

/* ===== Hero text entrance animations =====
   Staggered fade + rise from below. One-shot only (no loop).
   Prefers-reduced-motion users see content immediately. */
@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(24px); filter: blur(4px); }
  to   { opacity: 1; transform: translateY(0);    filter: blur(0); }
}
@keyframes heroLineReveal {
  from { opacity: 0; transform: translateY(40px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes heroGlow {
  from { text-shadow: 0 0 0 rgba(200, 90, 42, 0); }
  to   { text-shadow: 0 0 30px rgba(200, 90, 42, 0.45), 0 0 60px rgba(200, 90, 42, 0.2); }
}
@keyframes heroLineExpand {
  from { width: 0; opacity: 0; }
  to   { width: 28px; opacity: 0.6; }
}

/* Slogan — small, all-caps, tracked */
.hero__slogan {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--terracotta-light);
  margin: 0;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  opacity: 0;
  animation: heroFadeUp 0.9s 0.2s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
  /* Drop shadow so it reads on any video frame */
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.45);
}
.hero__slogan::before,
.hero__slogan::after {
  content: '';
  display: inline-block;
  width: 0;
  height: 1px;
  background: var(--terracotta-light);
  animation: heroLineExpand 1.1s 0.6s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}

/* Main tagline — massive serif */
.hero__title {
  font-family: var(--font-display);
  font-weight: 300;
  color: var(--ivory);
  margin: 0;
  letter-spacing: -0.035em;
  line-height: 0.98;
  font-size: clamp(44px, 8.5vw, 120px);
  max-width: 18ch;
  /* Drop shadow makes every pixel readable regardless of video colours */
  text-shadow:
    0 2px 20px rgba(0, 0, 0, 0.55),
    0 1px 3px rgba(0, 0, 0, 0.4);
}

/* Each line reveals on its own, staggered */
.hero__title-line {
  display: block;
  opacity: 0;
  animation: heroLineReveal 1s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}
.hero__title-line:nth-child(1) { animation-delay: 0.45s; }
.hero__title-line:nth-child(2) { animation-delay: 0.65s; }
.hero__title-line:nth-child(3) { animation-delay: 0.85s; }
.hero__title-line:nth-child(4) { animation-delay: 1.05s; }

.hero__title em {
  font-style: italic;
  color: var(--terracotta-light);
  font-weight: 300;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  /* Subtle warm glow on the accent word only — gives it magazine-cover presence */
  animation: heroGlow 1.6s 1.2s ease-out forwards;
  position: relative;
  display: inline-block;
}
/* A thin animated underline under the italic accent word — Majeli-style */
.hero__title em::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0.08em;
  width: 100%;
  height: 1px;
  background: var(--terracotta-light);
  transform: scaleX(0);
  transform-origin: left center;
  animation: heroUnderline 1.2s 1.4s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
  opacity: 0.5;
}
@keyframes heroUnderline {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

.hero__sub {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: clamp(15px, 1.4vw, 18px);
  line-height: 1.55;
  color: rgba(247, 242, 234, 0.92);
  margin: var(--sp-2) 0 var(--sp-1);
  max-width: 54ch;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.5);
  opacity: 0;
  animation: heroFadeUp 1s 1.3s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}

/* Inline nav pills */
.hero__pills {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem 0.8rem;
  margin-top: var(--sp-3);
  opacity: 0;
  animation: heroFadeUp 1s 1.5s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}
.hero__pills a {
  color: var(--ivory);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0.02em;
  padding: 10px 20px;
  border: 1px solid rgba(247, 242, 234, 0.28);
  border-radius: 999px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  background: rgba(247, 242, 234, 0.08);
  transition: all .25s var(--ease-out);
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}
.hero__pills a:hover {
  background: var(--terracotta);
  border-color: var(--terracotta);
  color: var(--ivory);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(200, 90, 42, 0.4);
}
.hero__pills a:first-child {
  background: var(--terracotta);
  border-color: var(--terracotta);
  box-shadow: 0 6px 24px rgba(200, 90, 42, 0.35);
}
.hero__pills a:first-child:hover {
  background: var(--terracotta-deep);
  border-color: var(--terracotta-deep);
}
.hero__pills-sep {
  color: rgba(247, 242, 234, 0.35);
  font-size: 14px;
  display: none;
}

/* Corner meta */
.hero__meta {
  position: absolute;
  bottom: var(--sp-4);
  z-index: 3;
  display: none;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: rgba(247, 242, 234, 0.55);
  opacity: 0;
  animation: heroFadeUp 0.8s 1.8s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.5);
}
.hero__meta--left  { left: var(--gutter); }
.hero__meta--right { right: var(--gutter); }
.hero__meta-dot { opacity: 0.6; }
@media (min-width: 900px) { .hero__meta { display: flex; } }

/* Scroll indicator */
.hero__scroll {
  position: absolute;
  bottom: var(--sp-3);
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(247, 242, 234, 0.55);
  text-decoration: none;
  transition: color .2s;
  opacity: 0;
  animation: heroFadeUp 0.8s 2s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}
.hero__scroll:hover { color: var(--ivory); }
.hero__scroll svg {
  width: 14px;
  height: 14px;
  animation: scrollBounce 2.4s 2.5s ease-in-out infinite;
}
@keyframes scrollBounce {
  0%, 100% { transform: translateY(0); opacity: 0.55; }
  50%      { transform: translateY(4px); opacity: 1; }
}
@media (max-width: 600px) {
  .hero__scroll { display: none; }
}

/* Respect user's motion preferences — show everything immediately */
@media (prefers-reduced-motion: reduce) {
  .hero__slogan,
  .hero__title-line,
  .hero__sub,
  .hero__pills,
  .hero__meta,
  .hero__scroll {
    opacity: 1 !important;
    animation: none !important;
    transform: none !important;
  }
  .hero__slogan::before,
  .hero__slogan::after {
    width: 28px !important;
    opacity: 0.6 !important;
    animation: none !important;
  }
  .hero__title em::after {
    transform: scaleX(1) !important;
    animation: none !important;
  }
  .hero__media video,
  .hero__media img { animation: none !important; }
}

/* Mobile hero tweaks */
@media (max-width: 600px) {
  .hero {
    padding: calc(var(--header-h) + var(--sp-3)) 1.2rem var(--sp-5);
    min-height: 92svh;
  }
  .hero__center { gap: 1rem; }
  .hero__slogan {
    font-size: 10px;
    letter-spacing: 0.28em;
  }
  .hero__slogan::before,
  .hero__slogan::after { width: 18px; margin: 0; }
  .hero__title {
    font-size: clamp(38px, 13vw, 64px);
    letter-spacing: -0.025em;
    line-height: 1.02;
    max-width: 14ch;
  }
  .hero__sub {
    font-size: 14px;
    max-width: 40ch;
  }
  .hero__pills { gap: 0.4rem; }
  .hero__pills a {
    font-size: 13px;
    padding: 9px 16px;
  }
}

/* Section marker — the page flow below the hero */


/* ---------- Value / stats strip ---------- */
.stats-strip {
  border-top: 1px solid var(--ink-line);
  border-bottom: 1px solid var(--ink-line);
  padding: var(--sp-5) 0;
  background: var(--paper);
}
.stats-strip__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--sp-4);
}
@media (min-width: 900px) { .stats-strip__grid { grid-template-columns: repeat(4, 1fr); } }
.stats-strip__item { border-left: 1px solid var(--ink-line); padding-left: var(--sp-4); }
.stats-strip__num {
  font-family: var(--font-display);
  font-size: var(--step-4);
  font-weight: 300;
  color: var(--ink);
  line-height: 1;
  margin-bottom: 0.4rem;
  letter-spacing: -0.02em;
}
.stats-strip__num em { font-style: italic; color: var(--terracotta); }
.stats-strip__label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--stone);
}

/* ---------- Editorial heading pattern ---------- */
.section-head {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-4);
  margin-bottom: var(--sp-6);
}
@media (min-width: 900px) {
  .section-head { grid-template-columns: 1fr 1.3fr; gap: var(--sp-6); align-items: end; }
}
.section-head__title h2 {
  margin: 0;
  font-weight: 300;
  letter-spacing: -0.025em;
}
.section-head__body { max-width: 55ch; }

/* ---------- House card ---------- */
.properties-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-5);
}
@media (min-width: 720px) { .properties-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .properties-grid { grid-template-columns: repeat(3, 1fr); } }

.house-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--white);
  transition: transform .45s var(--ease-out), box-shadow .4s var(--ease-out);
  text-decoration: none;
  color: inherit;
  overflow: hidden;
}
.house-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 60px -20px rgba(11,27,63,0.18);
}
.house-card__image {
  position: relative;
  aspect-ratio: 4/3;
  overflow: hidden;
  background: var(--ivory-deep);
}
.house-card__image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .9s var(--ease-out);
}
.house-card:hover .house-card__image img { transform: scale(1.04); }
.house-card__placeholder {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, var(--ivory-deep) 0%, var(--ivory) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--stone);
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--step-2);
}
.house-card__cat {
  position: absolute;
  top: var(--sp-3);
  left: var(--sp-3);
  background: rgba(247,242,234,0.95);
  color: var(--ink);
  padding: 0.4rem 0.8rem;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.house-card__body {
  padding: var(--sp-4);
  flex: 1;
  display: flex;
  flex-direction: column;
}
.house-card__name {
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-weight: 400;
  letter-spacing: -0.01em;
  margin: 0 0 0.4rem;
  color: var(--ink);
}
.house-card__tagline {
  font-style: italic;
  color: var(--terracotta-deep);
  font-family: var(--font-display);
  font-weight: 300;
  margin: 0 0 var(--sp-3);
  font-size: var(--step-0);
}
.house-card__specs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1rem;
  margin-top: auto;
  padding-top: var(--sp-3);
  border-top: 1px solid var(--ink-line);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--stone);
}
.house-card__price {
  margin-top: var(--sp-3);
  font-family: var(--font-display);
  font-size: var(--step-1);
  font-weight: 400;
  color: var(--ink);
}
.house-card__price .from {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--stone);
  display: block;
  margin-bottom: 0.2rem;
}
.house-card__price em { font-style: italic; color: var(--terracotta); font-weight: 300; }

/* ---------- Process steps ---------- */
.process-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--sp-4);
}
.process-step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--sp-4);
  padding: var(--sp-5) 0;
  border-top: 1px solid var(--ink-line);
  align-items: start;
}
.process-step:last-child { border-bottom: 1px solid var(--ink-line); }
.process-step__num {
  font-family: var(--font-display);
  font-size: var(--step-5);
  font-weight: 300;
  font-style: italic;
  color: var(--terracotta);
  line-height: 0.9;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  min-width: 4ch;
}
.process-step__title {
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-weight: 400;
  margin: 0 0 var(--sp-2);
  letter-spacing: -0.015em;
}
.process-step__body { max-width: 60ch; color: var(--charcoal-soft); }

/* ---------- Values / pillars ---------- */
.pillars {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-4);
  border-top: 1px solid var(--ink-line);
}
@media (min-width: 720px) { .pillars { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .pillars { grid-template-columns: repeat(3, 1fr); } }
.pillar {
  padding: var(--sp-5) var(--sp-4);
  border-bottom: 1px solid var(--ink-line);
}
@media (min-width: 720px) { .pillar:nth-child(odd) { border-right: 1px solid var(--ink-line); } }
@media (min-width: 1080px) {
  .pillar { border-right: 1px solid var(--ink-line); }
  .pillar:nth-child(3n) { border-right: none; }
  .pillar:nth-child(odd) { border-right: 1px solid var(--ink-line); }
  .pillar:nth-child(3n) { border-right: none; }
}
.pillar__num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin-bottom: var(--sp-3);
}
.pillar__title {
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-weight: 400;
  margin: 0 0 var(--sp-2);
}
.pillar__body { color: var(--charcoal-soft); margin: 0; font-size: var(--step-0); }

/* ---------- Pull quote / scripture card ---------- */
.scripture {
  padding: var(--sp-7) var(--sp-4);
  text-align: center;
  background: var(--ink);
  color: var(--ivory);
}
.scripture__quote {
  font-family: var(--font-display);
  font-size: var(--step-4);
  font-style: italic;
  font-weight: 300;
  line-height: 1.25;
  max-width: 24ch;
  margin: 0 auto var(--sp-3);
  font-variation-settings: "opsz" 144, "SOFT" 100;
  color: var(--ivory);
}
.scripture__quote::before { content: '\201C'; color: var(--terracotta); font-size: 1.2em; line-height: 0; vertical-align: -0.2em; margin-right: 0.05em; }
.scripture__quote::after { content: '\201D'; color: var(--terracotta); font-size: 1.2em; line-height: 0; vertical-align: -0.2em; margin-left: 0.05em; }
.scripture__attr {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--terracotta-light);
}

/* ---------- Applications / forms / inputs ---------- */
.field { display: flex; flex-direction: column; gap: 0.5rem; }
.field label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
}
.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field input[type="number"],
.field input[type="date"],
.field input[type="password"],
.field select,
.field textarea {
  width: 100%;
  padding: 1rem 1.1rem;
  border: 1px solid var(--ink-line);
  border-radius: 2px;
  background: var(--white);
  color: var(--charcoal);
  font-size: var(--step-0);
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(11,27,63,0.08);
}
.field textarea { min-height: 140px; resize: vertical; }
.field__hint { font-size: var(--step--1); color: var(--stone); }
.field--error input, .field--error select, .field--error textarea { border-color: var(--red-warn); }
.field__error { color: var(--red-warn); font-size: var(--step--1); }

/* Radio/check cards */
.choice-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: var(--sp-2); }
.choice {
  border: 1px solid var(--ink-line);
  padding: var(--sp-3);
  cursor: pointer;
  transition: all .2s;
  background: var(--white);
  border-radius: 2px;
  position: relative;
}
.choice input { position: absolute; opacity: 0; }
.choice:hover { border-color: var(--ink); }
.choice.is-selected { border-color: var(--terracotta); background: rgba(200,90,42,0.05); }
.choice__title { font-weight: 500; font-size: var(--step-0); color: var(--ink); margin-bottom: 0.2rem; }
.choice__sub { font-size: var(--step--1); color: var(--stone); }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: var(--ivory); margin-top: var(--sp-8); }
.site-footer h5 {
  color: var(--ivory);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin: 0 0 var(--sp-3);
  font-weight: 500;
  color: var(--terracotta-light);
}
.site-footer__top {
  overflow: hidden;
  border-bottom: 1px solid rgba(247,242,234,0.1);
}
.site-footer__marquee {
  display: flex;
  gap: 2.5rem;
  align-items: center;
  padding: var(--sp-3) 0;
  white-space: nowrap;
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--step-3);
  font-weight: 300;
  color: var(--ivory);
  animation: marquee 40s linear infinite;
}
.site-footer__marquee span[aria-hidden="true"] { color: var(--terracotta); }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.site-footer__main {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--sp-6) var(--gutter);
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-5);
}
@media (min-width: 900px) { .site-footer__main { grid-template-columns: 1.2fr 2fr; gap: var(--sp-6); } }
.site-footer__tagline {
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-weight: 300;
  font-style: italic;
  color: var(--ivory);
  line-height: 1.2;
  margin: 0 0 var(--sp-4);
  max-width: 18ch;
}
.site-footer__contact { font-style: normal; font-size: var(--step--1); color: var(--stone-soft); line-height: 1.8; }
.site-footer__contact a { color: var(--ivory); }
.site-footer__contact a:hover { color: var(--terracotta-light); }
.site-footer__cols {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--sp-5);
}
@media (min-width: 720px) { .site-footer__cols { grid-template-columns: repeat(4, 1fr); } }
.site-footer__cols ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.site-footer__cols a { color: var(--ivory); font-size: var(--step-0); }
.site-footer__cols a:hover { color: var(--terracotta-light); }
.site-footer__base {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--sp-4) var(--gutter);
  border-top: 1px solid rgba(247,242,234,0.1);
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2) var(--sp-4);
  justify-content: space-between;
  font-size: var(--step--2);
  color: var(--stone-soft);
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.site-footer__base a { color: var(--ivory); }
.site-footer__legal { display: flex; gap: 1rem; }
.site-footer__credit em { color: var(--terracotta-light); font-style: italic; font-family: var(--font-display); text-transform: none; letter-spacing: 0; }

/* ---------- Calculator ---------- */
.calc-card {
  background: var(--white);
  padding: clamp(1.5rem, 3vw, 3rem);
  border-radius: 4px;
  box-shadow: 0 40px 80px -30px rgba(11,27,63,0.15);
  border: 1px solid var(--ink-line);
}
.calc-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-5);
  align-items: start;
}
@media (min-width: 900px) { .calc-grid { grid-template-columns: 1.1fr 1fr; gap: var(--sp-6); } }

.calc-inputs { display: flex; flex-direction: column; gap: var(--sp-3); }
.calc-result {
  background: var(--ink);
  color: var(--ivory);
  padding: var(--sp-5);
  border-radius: 4px;
  position: sticky;
  top: calc(var(--header-h) + 1rem);
}
.calc-result h3 { color: var(--ivory); margin-bottom: var(--sp-3); font-weight: 400; }
.calc-result__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: var(--sp-3) 0;
  border-bottom: 1px solid rgba(247,242,234,0.12);
  gap: 1rem;
}
.calc-result__row:last-of-type { border-bottom: none; }
.calc-result__label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--stone-soft);
}
.calc-result__value {
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-weight: 400;
  color: var(--ivory);
  font-variant-numeric: tabular-nums;
}
.calc-result__value--large {
  font-size: var(--step-4);
  font-weight: 300;
  color: var(--terracotta-light);
  font-style: italic;
  line-height: 1;
  font-variation-settings: "opsz" 144, "SOFT" 100;
}
.calc-result__disclaimer {
  font-size: var(--step--2);
  color: var(--stone-soft);
  line-height: 1.5;
  margin-top: var(--sp-4);
  border-top: 1px solid rgba(247,242,234,0.12);
  padding-top: var(--sp-3);
}
.calc-result__cta { margin-top: var(--sp-4); }

.slider-row { display: flex; flex-direction: column; gap: 0.7rem; }
.slider-row__label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
}
.slider-row__value {
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-style: italic;
  font-weight: 400;
  color: var(--terracotta);
  letter-spacing: -0.01em;
  text-transform: none;
}
input[type="range"].range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  background: var(--ivory-deep);
  border-radius: 0;
  outline: none;
}
input[type="range"].range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  background: var(--terracotta);
  border-radius: 50%;
  cursor: grab;
  border: 3px solid var(--white);
  box-shadow: 0 2px 10px rgba(11,27,63,0.25);
  transition: transform .2s;
}
input[type="range"].range::-moz-range-thumb {
  width: 22px;
  height: 22px;
  background: var(--terracotta);
  border-radius: 50%;
  cursor: grab;
  border: 3px solid var(--white);
  box-shadow: 0 2px 10px rgba(11,27,63,0.25);
}
input[type="range"].range:active::-webkit-slider-thumb { transform: scale(1.15); cursor: grabbing; }

.seg-control {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border: 1px solid var(--ink-line);
  border-radius: 2px;
  overflow: hidden;
  background: var(--white);
}
.seg-control__btn {
  padding: 0.9rem 0.5rem;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: all .2s;
  border-right: 1px solid var(--ink-line);
}
.seg-control__btn:last-child { border-right: none; }
.seg-control__btn:hover { background: var(--ivory-deep); }
.seg-control__btn.is-active { background: var(--ink); color: var(--ivory); }

/* ---------- Chatbot widget ---------- */
.chat-toggle {
  position: fixed;
  right: 1.5rem;
  bottom: 1.5rem;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--ivory);
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 30px -6px rgba(11,27,63,0.35);
  transition: transform .3s var(--ease-out), background .3s;
  cursor: pointer;
}
.chat-toggle:hover { transform: translateY(-3px); background: var(--terracotta); }
.chat-toggle svg { width: 24px; height: 24px; }
.chat-toggle__pulse {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid var(--terracotta);
  opacity: 0;
  animation: chatPulse 2.5s var(--ease-out) infinite;
}
@keyframes chatPulse {
  0% { opacity: 0.8; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.4); }
}

.chat-panel {
  position: fixed;
  right: 1.5rem;
  bottom: 1.5rem;
  width: min(400px, calc(100vw - 2rem));
  height: min(620px, calc(100svh - 3rem));
  background: var(--white);
  border-radius: 4px;
  box-shadow: 0 40px 80px -20px rgba(11,27,63,0.35);
  display: none;
  flex-direction: column;
  z-index: 41;
  overflow: hidden;
  border: 1px solid var(--ink-line);
}
.chat-panel.is-open { display: flex; animation: chatSlide .35s var(--ease-out); }
@keyframes chatSlide { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

.chat-panel__head {
  padding: var(--sp-3) var(--sp-4);
  background: var(--ink);
  color: var(--ivory);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
}
.chat-panel__title {
  font-family: var(--font-display);
  font-size: var(--step-1);
  font-weight: 400;
  letter-spacing: -0.01em;
  margin: 0;
}
.chat-panel__sub {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--terracotta-light);
  margin-top: 3px;
}
.chat-panel__close { font-size: 1.5rem; line-height: 1; color: var(--ivory); width: 36px; height: 36px; }

.chat-panel__body {
  flex: 1;
  overflow-y: auto;
  padding: var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  background: var(--paper);
}

.chat-msg { max-width: 85%; }
.chat-msg--bot {
  align-self: flex-start;
  background: var(--white);
  padding: 0.9rem 1.1rem;
  border-radius: 2px 14px 14px 14px;
  font-size: var(--step-0);
  line-height: 1.5;
  border: 1px solid var(--ink-line);
}
.chat-msg--user {
  align-self: flex-end;
  background: var(--ink);
  color: var(--ivory);
  padding: 0.9rem 1.1rem;
  border-radius: 14px 2px 14px 14px;
  font-size: var(--step-0);
}
.chat-msg--typing .typing-dot {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--stone);
  margin: 0 2px;
  animation: typingDot 1.2s infinite;
}
.chat-msg--typing .typing-dot:nth-child(2) { animation-delay: 0.15s; }
.chat-msg--typing .typing-dot:nth-child(3) { animation-delay: 0.3s; }
@keyframes typingDot { 0%, 60%, 100% { opacity: 0.3; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-4px); } }

.chat-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.5rem;
}
.chat-suggestion {
  background: var(--ivory-deep);
  border: 1px solid var(--ink-line);
  padding: 0.4rem 0.7rem;
  font-size: var(--step--1);
  border-radius: 100px;
  cursor: pointer;
  color: var(--ink);
  transition: all .2s;
}
.chat-suggestion:hover { background: var(--ink); color: var(--ivory); }

.chat-panel__foot {
  padding: var(--sp-3);
  border-top: 1px solid var(--ink-line);
  background: var(--white);
}
.chat-form { display: flex; gap: 0.5rem; align-items: end; }
.chat-input {
  flex: 1;
  resize: none;
  border: 1px solid var(--ink-line);
  padding: 0.7rem 0.9rem;
  border-radius: 2px;
  font-size: var(--step-0);
  min-height: 44px;
  max-height: 120px;
  background: var(--white);
}
.chat-input:focus { outline: none; border-color: var(--ink); }
.chat-send {
  width: 44px; height: 44px;
  background: var(--ink);
  color: var(--ivory);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s;
  border-radius: 2px;
}
.chat-send:hover { background: var(--terracotta); }
.chat-send:disabled { opacity: 0.4; cursor: not-allowed; }

.chat-panel__footer-note {
  text-align: center;
  font-size: var(--step--2);
  color: var(--stone);
  margin: 0.4rem 0 0;
  font-family: var(--font-mono);
  letter-spacing: 0.05em;
}

/* ---------- Multi-step application ---------- */
.apply-shell {
  max-width: 780px;
  margin: 0 auto;
}
.apply-progress {
  display: flex;
  gap: 0.4rem;
  margin-bottom: var(--sp-5);
}
.apply-progress__step {
  flex: 1;
  height: 3px;
  background: var(--ink-line);
  transition: background .3s;
  position: relative;
}
.apply-progress__step.is-done { background: var(--terracotta); }
.apply-progress__step.is-current { background: var(--ink); }
.apply-step { display: none; }
.apply-step.is-active { display: block; animation: stepFade .4s var(--ease-out); }
@keyframes stepFade { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.apply-step__eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin-bottom: 0.6rem;
}
.apply-step__title {
  font-family: var(--font-display);
  font-size: var(--step-4);
  font-weight: 300;
  margin: 0 0 var(--sp-2);
  letter-spacing: -0.02em;
}
.apply-step__sub { color: var(--charcoal-soft); margin-bottom: var(--sp-5); max-width: 58ch; }
.apply-grid { display: grid; grid-template-columns: 1fr; gap: var(--sp-3); }
@media (min-width: 720px) { .apply-grid--2 { grid-template-columns: 1fr 1fr; } }
.apply-nav { display: flex; gap: var(--sp-3); margin-top: var(--sp-5); justify-content: space-between; }

/* ---------- Utility ---------- */
.flow > * + * { margin-top: var(--sp-3); }
.flow-lg > * + * { margin-top: var(--sp-5); }
.center { text-align: center; }
.hidden { display: none !important; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* Entrance animations */
.fade-up { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); }
.fade-up.is-visible { opacity: 1; transform: translateY(0); }
.stagger > * { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out); }
.stagger.is-visible > * { opacity: 1; transform: translateY(0); }
.stagger.is-visible > *:nth-child(1) { transition-delay: .05s; }
.stagger.is-visible > *:nth-child(2) { transition-delay: .12s; }
.stagger.is-visible > *:nth-child(3) { transition-delay: .19s; }
.stagger.is-visible > *:nth-child(4) { transition-delay: .26s; }
.stagger.is-visible > *:nth-child(5) { transition-delay: .33s; }
.stagger.is-visible > *:nth-child(6) { transition-delay: .4s; }

/* ---------- Gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-2);
}
@media (min-width: 720px) {
  .gallery-grid {
    grid-template-columns: repeat(12, 1fr);
    grid-auto-rows: 160px;
  }
}
.gallery-item {
  overflow: hidden;
  position: relative;
  background: var(--ivory-deep);
}
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease-out); }
.gallery-item:hover img { transform: scale(1.05); }
@media (min-width: 720px) {
  .gallery-item:nth-child(8n+1) { grid-column: span 5; grid-row: span 2; }
  .gallery-item:nth-child(8n+2) { grid-column: span 4; grid-row: span 1; }
  .gallery-item:nth-child(8n+3) { grid-column: span 3; grid-row: span 1; }
  .gallery-item:nth-child(8n+4) { grid-column: span 4; grid-row: span 2; }
  .gallery-item:nth-child(8n+5) { grid-column: span 3; grid-row: span 1; }
  .gallery-item:nth-child(8n+6) { grid-column: span 5; grid-row: span 1; }
  .gallery-item:nth-child(8n+7) { grid-column: span 4; grid-row: span 2; }
  .gallery-item:nth-child(8n+8) { grid-column: span 8; grid-row: span 1; }
}

/* ---------- Team ---------- */
.team-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-5);
}
@media (min-width: 720px) { .team-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .team-grid { grid-template-columns: repeat(3, 1fr); } }
.team-card__photo {
  aspect-ratio: 3/4;
  background: var(--ivory-deep);
  margin-bottom: var(--sp-3);
  overflow: hidden;
}
.team-card__photo img { width: 100%; height: 100%; object-fit: cover; }
.team-card__name {
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-weight: 400;
  margin: 0 0 0.2rem;
  letter-spacing: -0.01em;
}
.team-card__role {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin-bottom: 0.6rem;
}
.team-card__bio { color: var(--charcoal-soft); font-size: var(--step-0); }

/* ---------- News / Articles ---------- */
.article-list { display: grid; gap: var(--sp-5); }
.article-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-3);
  padding: var(--sp-4) 0;
  border-top: 1px solid var(--ink-line);
  text-decoration: none;
  color: inherit;
}
.article-card:last-child { border-bottom: 1px solid var(--ink-line); }
@media (min-width: 720px) {
  .article-card { grid-template-columns: 240px 1fr; gap: var(--sp-4); align-items: start; }
}
.article-card__image {
  aspect-ratio: 4/3;
  overflow: hidden;
  background: var(--ivory-deep);
}
.article-card__image img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.article-card:hover .article-card__image img { transform: scale(1.04); }
.article-card__meta {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--stone);
  margin-bottom: 0.4rem;
}
.article-card__title {
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-weight: 400;
  margin: 0 0 0.6rem;
  letter-spacing: -0.015em;
  color: var(--ink);
  transition: color .2s;
}
.article-card:hover .article-card__title { color: var(--terracotta); }
.article-card__excerpt { color: var(--charcoal-soft); margin: 0; max-width: 65ch; }

/* ---------- Cta block ---------- */
.cta-block {
  padding: var(--sp-7) var(--gutter);
  background: var(--ink);
  color: var(--ivory);
  text-align: center;
  margin: var(--sp-6) 0;
}
.cta-block h2 { color: var(--ivory); max-width: 16ch; margin: 0 auto var(--sp-4); font-weight: 300; }
.cta-block p { max-width: 50ch; margin: 0 auto var(--sp-4); color: rgba(247,242,234,0.8); }

/* ---------- Success / flash ---------- */
.flash {
  padding: var(--sp-3) var(--sp-4);
  margin-bottom: var(--sp-4);
  border-left: 3px solid;
  background: var(--white);
  font-size: var(--step-0);
}
.flash--ok { border-color: var(--green-ok); color: var(--green-ok); }
.flash--err { border-color: var(--red-warn); color: var(--red-warn); }

/* ==========================================================================
   FILE UPLOAD
   Professional, admin-panel-like look. Intentionally uses high-specificity
   selectors (.apply-file-drop .ribane-upload) to avoid ever being overridden.
   ========================================================================== */

.apply-file-drop {
  grid-column: 1 / -1 !important;
  width: 100%;
}

.apply-file-drop > label {
  display: block;
  margin: 0 0 0.75rem 0;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
  font-weight: 500;
}

/* Main card — clean, bordered, obviously a form control */
.apply-file-drop .ribane-upload {
  display: block !important;
  border: 1px solid var(--ink-line, #D8D0BE);
  background: #FFFFFF;
  border-radius: 8px;
  padding: 0;
  overflow: hidden;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
  position: relative;
}
.apply-file-drop .ribane-upload:hover,
.apply-file-drop .ribane-upload.is-hover {
  border-color: var(--terracotta, #C85A2A);
  background: #FFFBF6;
  box-shadow: 0 4px 16px rgba(200, 90, 42, 0.1);
}

/* Hidden native file input */
.apply-file-drop .ribane-upload__native {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

/* Top section — prompt */
.apply-file-drop .ribane-upload__prompt {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 28px 20px 24px;
  gap: 12px;
}

.apply-file-drop .ribane-upload__icon {
  width: 56px !important;
  height: 56px !important;
  min-width: 56px;
  min-height: 56px;
  max-width: 56px;
  max-height: 56px;
  border-radius: 50%;
  background: var(--terracotta, #C85A2A);
  color: #FFFFFF;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(200, 90, 42, 0.3);
  flex-shrink: 0;
}
.apply-file-drop .ribane-upload__icon svg {
  width: 24px !important;
  height: 24px !important;
  display: block;
  stroke: currentColor;
  fill: none;
}

.apply-file-drop .ribane-upload__title {
  font-family: var(--font-display, 'Fraunces', serif);
  font-size: 22px;
  font-weight: 400;
  color: var(--ink, #0B1B3F);
  margin: 0;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.apply-file-drop .ribane-upload__subtitle {
  color: var(--charcoal-soft, #525252);
  font-size: 14px;
  line-height: 1.5;
  margin: 0;
  max-width: 42ch;
}

.apply-file-drop .ribane-upload__button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--terracotta, #C85A2A) !important;
  color: #FFFFFF !important;
  border: 0 !important;
  padding: 12px 24px !important;
  font-family: var(--font-body, 'Instrument Sans', sans-serif);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer !important;
  border-radius: 6px;
  margin-top: 4px;
  min-height: 48px;
  min-width: 200px;
  transition: background .15s ease, transform .1s ease;
  text-decoration: none !important;
  line-height: 1;
}
.apply-file-drop .ribane-upload__button:hover {
  background: var(--terracotta-deep, #A04820) !important;
}
.apply-file-drop .ribane-upload__button:active {
  transform: translateY(1px);
}
.apply-file-drop .ribane-upload__button svg {
  width: 18px !important;
  height: 18px !important;
  stroke: currentColor;
  fill: none;
  flex-shrink: 0;
}

.apply-file-drop .ribane-upload__or {
  font-size: 11px;
  color: var(--stone, #8C8579);
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 2px 0 0;
}

/* Bottom panel — examples + constraints */
.apply-file-drop .ribane-upload__info {
  background: var(--paper, #F4F2EE);
  border-top: 1px solid var(--ink-line, #D8D0BE);
  padding: 16px 20px;
}
.apply-file-drop .ribane-upload__info-label {
  font-family: var(--font-mono, monospace);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--stone, #8C8579);
  margin: 0 0 8px 0;
  font-weight: 500;
}
.apply-file-drop .ribane-upload__info ul {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 0 10px 0 !important;
  font-size: 13px;
  line-height: 1.7;
  color: var(--charcoal-soft, #525252);
}
.apply-file-drop .ribane-upload__info li {
  display: flex !important;
  align-items: baseline;
  gap: 8px;
  padding: 2px 0;
}
.apply-file-drop .ribane-upload__info li::before {
  content: '✓' !important;
  color: var(--green-ok, #2B6A4A);
  font-weight: 700;
  flex-shrink: 0;
}
.apply-file-drop .ribane-upload__constraints {
  font-size: 11px;
  font-family: var(--font-mono, monospace);
  color: var(--stone, #8C8579);
  margin: 0;
  padding-top: 10px;
  border-top: 1px solid var(--ink-line, #D8D0BE);
  letter-spacing: 0.03em;
}

/* File list (after user picks files) */
.apply-file-drop .ribane-upload__files {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
  background: var(--paper, #F4F2EE);
  border-top: 1px solid var(--ink-line, #D8D0BE);
}
.apply-file-drop .ribane-upload__files:empty {
  display: none !important;
}
.apply-file-drop .ribane-upload__files li {
  display: flex !important;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: #FFFFFF;
  border-bottom: 1px solid var(--ink-line, #D8D0BE);
  font-size: 14px;
}
.apply-file-drop .ribane-upload__files li:last-child {
  border-bottom: 0;
}
.apply-file-drop .ribane-upload__files li::before {
  content: '';
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background-color: rgba(43, 106, 74, 0.12);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232B6A4A' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 16px;
  flex-shrink: 0;
}
.apply-file-drop .ribane-upload__files .ribane-upload__name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 500;
  color: var(--ink, #0B1B3F);
}
.apply-file-drop .ribane-upload__files .ribane-upload__size {
  color: var(--stone, #8C8579);
  font-family: var(--font-mono, monospace);
  font-size: 11px;
}
.apply-file-drop .ribane-upload__files .ribane-upload__remove {
  color: var(--red-warn, #A93226) !important;
  background: transparent !important;
  border: 1px solid transparent !important;
  font-size: 22px !important;
  line-height: 1 !important;
  cursor: pointer !important;
  padding: 4px 10px !important;
  border-radius: 4px;
  flex-shrink: 0;
  min-width: 36px;
  min-height: 36px;
  font-weight: 300;
}
.apply-file-drop .ribane-upload__files .ribane-upload__remove:hover {
  background: rgba(169, 50, 38, 0.1) !important;
  border-color: var(--red-warn, #A93226) !important;
}

/* Small-screen tuning */
@media (max-width: 520px) {
  .apply-file-drop .ribane-upload__prompt {
    padding: 22px 16px 20px;
    gap: 10px;
  }
  .apply-file-drop .ribane-upload__title {
    font-size: 19px;
  }
  .apply-file-drop .ribane-upload__button {
    width: 100%;
    min-width: 0;
    padding: 14px 20px !important;
  }
  .apply-file-drop .ribane-upload__info { padding: 14px 16px; }
  .apply-file-drop .ribane-upload__files li { padding: 12px 16px; }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  .apply-file-drop .ribane-upload,
  .apply-file-drop .ribane-upload__button {
    transition: none !important;
  }
}

/* ---------- Apply step field widths ---------- */
.apply-field--full  { grid-column: 1 / -1; }
.apply-field--half  { grid-column: span 1; }
@media (min-width: 720px) { .apply-field--half { grid-column: span 1; } }
.apply-field--third { grid-column: span 1; }

/* ---------- Section image (Ombali-style) ---------- */
.section-with-bg-image {
  position: relative;
  overflow: hidden;
}
.section-with-bg-image::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--bg-url);
  background-size: cover;
  background-position: center;
  opacity: 0.25;
  z-index: 0;
  filter: saturate(0.8);
}
.section-with-bg-image > * { position: relative; z-index: 1; }

.process-step--with-image {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-4);
}
@media (min-width: 900px) {
  .process-step--with-image {
    grid-template-columns: 1fr 1.3fr;
    align-items: center;
  }
  .process-step--with-image.is-reverse { direction: rtl; }
  .process-step--with-image.is-reverse > * { direction: ltr; }
}
.process-step__image {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--ivory-deep);
}
.process-step__image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .9s var(--ease-out);
}
.process-step--with-image:hover .process-step__image img { transform: scale(1.04); }

/* ---------- 3D viewer ---------- */
.three-d-viewer {
  aspect-ratio: 16/10;
  background: var(--ink);
  border: 1px solid var(--ink-line);
  overflow: hidden;
}
.three-d-viewer iframe,
.three-d-viewer model-viewer {
  width: 100%; height: 100%; border: 0;
}
