/* =========================================================
   TRUEVEST — تروفيست للاستثمار
   Palette & type derived from the brand logo
   ========================================================= */

:root {
  /* Brand colors (from logo) */
  --night: #17150e;
  --olive: #2a271c;        /* logo dark background */
  --olive-2: #35311f;
  --gold: #b8975a;         /* logo gold */
  --gold-hi: #e2c98f;
  --gold-lo: #8a6a33;
  --navy: #1f2a3c;         /* logo navy (light version) */
  --navy-2: #172131;
  --paper: #f4f1ea;
  --stone: #e7e1d3;

  --ink: var(--navy);
  --ink-soft: #5a6278;
  --cream: #efe8d8;
  --cream-soft: rgba(239, 232, 216, 0.66);
  --line-dark: rgba(226, 201, 143, 0.16);
  --line-light: rgba(31, 42, 60, 0.12);

  --grad-gold: linear-gradient(115deg, #8a6a33 0%, #e2c98f 36%, #b8975a 62%, #8a6a33 100%);

  /* Type */
  --f-ar: "Alexandria", "Segoe UI", Tahoma, sans-serif;
  --f-serif: "Playfair Display", Georgia, serif;
  --f-wide: "Jost", "Segoe UI", sans-serif;
  --f-head: var(--f-ar);
  --f-body: var(--f-ar);

  /* Motion */
  --ease: cubic-bezier(0.16, 0.84, 0.24, 1);
  --ease-io: cubic-bezier(0.76, 0, 0.24, 1);

  /* Layout */
  --gutter: clamp(16px, 4.5vw, 64px);
  --max: 1360px;
  --radius: 18px;
  --header-h: 84px;
}

html[lang="en"] {
  --f-head: var(--f-serif);
  --f-body: var(--f-wide);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 90px; }
body {
  margin: 0;
  background: var(--olive);
  color: var(--cream);
  font-family: var(--f-body);
  font-weight: 300;
  font-size: 0.95rem;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.is-loading { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
h1, h2, h3, p, ul, ol, dl, dd, figure, blockquote { margin: 0; padding: 0; }
ul { list-style: none; }
::selection { background: var(--gold); color: var(--night); }

:focus-visible {
  outline: 2px solid var(--gold-hi);
  outline-offset: 4px;
  border-radius: 4px;
}

/* Film grain for a printed, tactile luxury feel */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 200;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

.skip-link {
  position: fixed;
  top: 12px;
  inset-inline-start: 12px;
  z-index: 300;
  padding: 10px 18px;
  background: var(--gold);
  color: var(--night);
  border-radius: 999px;
  transform: translateY(-160%);
  transition: transform 0.3s var(--ease);
}
.skip-link:focus { transform: none; }

.container {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { position: relative; padding-block: clamp(72px, 9vw, 132px); }

/* ---------- Type helpers ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--f-body);
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  color: var(--gold-hi);
  margin-bottom: 24px;
}
html[lang="en"] .eyebrow { letter-spacing: 0.32em; text-transform: uppercase; font-size: 0.72rem; }
.eyebrow::before {
  content: "";
  width: 38px;
  height: 1px;
  background: var(--grad-gold);
}
.eyebrow-dark { color: var(--gold-lo); }

.h2 {
  font-family: var(--f-head);
  font-weight: 400;
  font-size: clamp(1.8rem, 3.4vw, 3rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
  color: var(--cream);
}
html[lang="ar"] .h2 { font-weight: 300; line-height: 1.45; }
.h2-dark { color: var(--ink); }

.gold-text {
  background: var(--grad-gold);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: goldShift 8s ease-in-out infinite alternate;
  padding-bottom: 0.25em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

html[lang="en"] .gold-text { font-style: italic; }
@keyframes goldShift { to { background-position: 100% 0; } }

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 54px;
  padding: 0 32px;
  border-radius: 999px;
  font-family: var(--f-body);
  font-size: 0.95rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  overflow: hidden;
  isolation: isolate;
  transition: color 0.5s var(--ease), border-color 0.5s var(--ease), transform 0.4s var(--ease);
}
.btn span { position: relative; z-index: 1; }
.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: inherit;
  transform: translateY(101%);
  transition: transform 0.6s var(--ease);
}
.btn:hover::before { transform: translateY(0); }

.btn-gold { background: var(--grad-gold); background-size: 160% 100%; color: var(--night); font-weight: 500; }
.btn-gold::before { background: var(--cream); }

.btn-ghost { border: 1px solid rgba(226, 201, 143, 0.45); color: var(--cream); }
.btn-ghost::before { background: var(--gold); }
.btn-ghost:hover { color: var(--night); border-color: var(--gold); }

.btn-sm { min-height: 44px; padding: 0 22px; font-size: 0.85rem; }
.btn-block { width: 100%; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: 0.92rem;
  color: var(--gold-hi);
  padding-block: 6px;
}
.link-arrow i, .con-arrow, .to-top i, .works-hint i {
  position: relative;
  display: inline-block;
  width: 34px;
  height: 1px;
  background: currentColor;
  transition: width 0.5s var(--ease);
}
.link-arrow i::after, .con-arrow::after, .to-top i::after, .works-hint i::after {
  content: "";
  position: absolute;
  inset-inline-end: 0;
  top: -4px;
  width: 8px;
  height: 8px;
  border-top: 1px solid currentColor;
  border-inline-end: 1px solid currentColor;
  transform: rotate(45deg);
}
[dir="rtl"] .link-arrow i::after,
[dir="rtl"] .con-arrow::after,
[dir="rtl"] .works-hint i::after { transform: rotate(-135deg); }
.link-arrow:hover i { width: 52px; }

/* ---------- Loader ---------- */
.loader {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  pointer-events: none;
}
.loader-curtain {
  position: absolute;
  inset: 0;
  background: var(--night);
  transform-origin: top;
  transition: transform 1.1s var(--ease-io);
}
.loader-inner {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 18px;
  transition: opacity 0.6s ease, transform 1s var(--ease-io);
}
.loader-mark { width: clamp(140px, 22vw, 220px); overflow: visible; }
.lm-letter {
  font-family: var(--f-serif);
  font-size: 104px;
  font-weight: 500;
  fill: transparent;
  stroke: var(--gold);
  stroke-width: 0.8;
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
  animation: lmDraw 1.6s var(--ease) forwards, lmFill 0.8s ease 1.1s forwards;
}
.lm-v { animation-delay: 0.2s, 1.3s; }
.lm-arrow {
  fill: none;
  stroke: var(--paper);
  stroke-width: 3.2;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: lmArrow 0.9s var(--ease) 1.2s forwards;
}
.lm-head { fill: var(--paper); opacity: 0; animation: lmFade 0.3s ease 1.95s forwards; }
.loader-word {
  font-family: var(--f-wide);
  font-weight: 300;
  font-size: 0.9rem;
  letter-spacing: 0.9em;
  margin-inline-end: -0.9em;
  color: var(--cream-soft);
  opacity: 0;
  animation: lmFade 0.8s ease 1.4s forwards;
}
@keyframes lmDraw { to { stroke-dashoffset: 0; } }
@keyframes lmFill { to { fill: var(--gold); stroke-width: 0; } }
@keyframes lmArrow { to { stroke-dashoffset: 0; } }
@keyframes lmFade { to { opacity: 1; } }

body.is-loaded .loader-inner { opacity: 0; transform: translateY(-40px); }
body.is-loaded .loader-curtain { transform: scaleY(0); }
body.is-loaded .loader { visibility: hidden; transition: visibility 0s 1.3s; }

/* ---------- Cursor ---------- */
.cursor { display: none; }
@media (hover: hover) and (pointer: fine) {
  .cursor { display: block; position: fixed; inset: 0; z-index: 400; pointer-events: none; }
  .cursor-dot, .cursor-ring {
    position: fixed;
    top: 0;
    left: 0;
    border-radius: 50%;
    will-change: transform;
  }
  .cursor-dot { width: 6px; height: 6px; margin: -3px 0 0 -3px; background: var(--gold-hi); }
  .cursor-ring {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    margin: -19px 0 0 -19px;
    border: 1px solid rgba(226, 201, 143, 0.6);
    transition: width 0.4s var(--ease), height 0.4s var(--ease), margin 0.4s var(--ease), background-color 0.4s, border-color 0.4s;
  }
  .cursor-label { font-style: normal; font-size: 0.7rem; color: var(--night); opacity: 0; transition: opacity 0.3s; }
  .cursor.is-hover .cursor-ring { width: 64px; height: 64px; margin: -32px 0 0 -32px; background: rgba(226, 201, 143, 0.12); }
  .cursor.is-view .cursor-ring { width: 86px; height: 86px; margin: -43px 0 0 -43px; background: var(--gold-hi); border-color: var(--gold-hi); }
  .cursor.is-view .cursor-label { opacity: 1; }
  .cursor.is-view .cursor-dot { opacity: 0; }
}

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 100;
  transition: transform 0.6s var(--ease), background-color 0.5s ease, backdrop-filter 0.5s;
}
.site-header.is-scrolled {
  background: rgba(23, 21, 14, 0.72);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  backdrop-filter: blur(16px) saturate(1.2);
  border-bottom: 1px solid var(--line-dark);
}
.site-header.is-hidden { transform: translateY(-100%); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: var(--header-h);
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--gold); }
.brand-mark { width: 54px; height: 36px; color: var(--gold); }
.brand-text { display: grid; line-height: 1.1; }
.brand-ar { font-family: var(--f-ar); font-weight: 500; font-size: 0.92rem; color: var(--gold-hi); }
.brand-en { font-family: var(--f-wide); font-weight: 300; font-size: 0.62rem; letter-spacing: 0.55em; color: var(--cream-soft); }

.nav { display: flex; gap: clamp(18px, 2.4vw, 36px); }
.nav a {
  position: relative;
  font-size: 0.9rem;
  color: var(--cream-soft);
  padding-block: 6px;
  transition: color 0.3s;
}
.nav a::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 1px;
  background: var(--grad-gold);
  transform: scaleX(0);
  transform-origin: var(--origin-end, left);
  transition: transform 0.5s var(--ease);
}
[dir="rtl"] .nav a::after { transform-origin: right; }
.nav a:hover, .nav a.is-active { color: var(--cream); }
.nav a:hover::after, .nav a.is-active::after { transform: scaleX(1); }

.header-actions { display: flex; align-items: center; gap: 14px; }
.lang-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line-dark);
  font-family: var(--f-wide);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  transition: border-color 0.3s, background-color 0.3s, color 0.3s;
}
.lang-toggle [data-i18n] { font-family: var(--f-ar); }
html[lang="ar"] .lang-toggle [data-i18n] { font-family: var(--f-wide); }
.lang-toggle:hover { border-color: var(--gold); background: var(--gold); color: var(--night); }

.menu-toggle { display: none; width: 44px; height: 44px; position: relative; }
.menu-toggle span {
  position: absolute;
  inset-inline: 10px;
  height: 1px;
  background: var(--cream);
  transition: transform 0.5s var(--ease), top 0.5s var(--ease);
}
.menu-toggle span:first-child { top: 18px; }
.menu-toggle span:last-child { top: 26px; }
.menu-toggle[aria-expanded="true"] span:first-child { top: 22px; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:last-child { top: 22px; transform: rotate(-45deg); }

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--header-h) var(--gutter) 40px;
  background: var(--night);
  clip-path: circle(0% at 90% 4%);
  transition: clip-path 0.9s var(--ease-io);
}
[dir="rtl"] .mobile-menu { clip-path: circle(0% at 10% 4%); }
.mobile-menu.is-open { clip-path: circle(150% at 50% 0%); }
.mobile-nav { display: grid; gap: 6px; }
.mobile-nav a {
  font-family: var(--f-head);
  font-size: clamp(1.5rem, 6.5vw, 2.1rem);
  font-weight: 300;
  color: var(--cream);
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.8s var(--ease), color 0.3s;
}
.mobile-menu.is-open .mobile-nav a { opacity: 1; transform: none; }
.mobile-menu.is-open .mobile-nav a:nth-child(1) { transition-delay: 0.25s; }
.mobile-menu.is-open .mobile-nav a:nth-child(2) { transition-delay: 0.3s; }
.mobile-menu.is-open .mobile-nav a:nth-child(3) { transition-delay: 0.35s; }
.mobile-menu.is-open .mobile-nav a:nth-child(4) { transition-delay: 0.4s; }
.mobile-menu.is-open .mobile-nav a:nth-child(5) { transition-delay: 0.45s; }
.mobile-menu.is-open .mobile-nav a:nth-child(6) { transition-delay: 0.5s; }
.mobile-nav a:hover { color: var(--gold-hi); }
.mobile-menu-foot {
  margin-top: auto;
  font-family: var(--f-wide);
  font-weight: 200;
  letter-spacing: 0.7em;
  color: var(--gold);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: calc(var(--header-h) + 24px) var(--gutter) 110px;
  overflow: hidden;
  isolation: isolate;
}
.hero-glow {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(60% 50% at 75% 30%, rgba(184, 151, 90, 0.16), transparent 70%),
    radial-gradient(50% 60% at 10% 90%, rgba(31, 42, 60, 0.55), transparent 70%);
}
[dir="rtl"] .hero-glow {
  background:
    radial-gradient(60% 50% at 25% 30%, rgba(184, 151, 90, 0.16), transparent 70%),
    radial-gradient(50% 60% at 90% 90%, rgba(31, 42, 60, 0.55), transparent 70%);
}
.hero-copy {
  position: relative;
  z-index: 4;
  display: grid;
  justify-items: center;
  max-width: 1120px;
  text-align: center;
}
.hero-copy .eyebrow::after {
  content: "";
  width: 38px;
  height: 1px;
  background: var(--grad-gold);
}
.hero-title {
  font-family: var(--f-head);
  font-weight: 300;
  font-size: clamp(2.1rem, 4.3vw, 4.2rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 30px;
}
html[lang="ar"] .hero-title { line-height: 1.4; font-weight: 300; }
html[lang="en"] .hero-title { font-weight: 400; }
.hero-title .line { display: inline-block; overflow: hidden; padding-block: 0.04em; vertical-align: top; }
.hero-title .line > span { display: inline-block; }
.hero-lead {
  max-width: 36rem;
  margin-inline: auto;
  font-size: clamp(0.95rem, 1.1vw, 1.05rem);
  color: var(--cream-soft);
  margin-bottom: 40px;
}
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }

/* hero entrance (triggered after loader) */
.hero-in {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1s ease, transform 1.3s var(--ease);
  transition-delay: calc(var(--d, 0) * 0.12s + 0.2s);
}
.hero-title .hero-in { transform: translateY(110%); }
body.is-loaded .hero-in { opacity: 1; transform: none; }

/* Pinterest-style drifting columns */
.hero-pins {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
  padding-inline: 14px;
  overflow: hidden;
  opacity: 0;
  transform: scale(1.08);
  transition: opacity 1.6s ease 0.4s, transform 2.2s var(--ease) 0.4s;
}
body.is-loaded .hero-pins { opacity: 1; transform: none; }
.pin-col { overflow: hidden; }
.pin-col:nth-child(even) { margin-top: -90px; }
.pin-col:nth-child(3n) { margin-top: -180px; }

/* dark veil: keeps the centre calm so the headline reads */
.hero-veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(42% 48% at 50% 50%, rgba(42, 39, 28, 0.97) 0%, rgba(42, 39, 28, 0.9) 55%, rgba(42, 39, 28, 0.5) 100%),
    linear-gradient(180deg, rgba(42, 39, 28, 0.95) 0%, rgba(42, 39, 28, 0.2) 24%, transparent 70%, var(--olive) 100%);
}
.pin-track {
  display: grid;
  gap: 14px;
  animation: drift 46s linear infinite;
}
.pin-col--rev .pin-track { animation-direction: reverse; animation-duration: 54s; }
@keyframes drift { to { transform: translateY(calc(-50% - 7px)); } }

.hp {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4 / 4.4;
  background: linear-gradient(160deg, var(--olive-2), var(--navy));
}
.hp.tall { aspect-ratio: 3 / 4.6; }
.hp.mid { aspect-ratio: 4 / 5; }
.hp img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.8) contrast(1.05); }
.hp::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(226, 201, 143, 0.14);
  background: linear-gradient(180deg, transparent 50%, rgba(23, 21, 14, 0.35));
}

.hero-arc {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  z-index: 3;
  width: 100%;
  height: 60%;
  pointer-events: none;
}
[dir="rtl"] .hero-arc { transform: scaleX(-1); }
.hero-arc-path {
  fill: none;
  stroke: url(#g-gold);
  stroke: var(--gold);
  stroke-width: 1.2;
  vector-effect: non-scaling-stroke;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  transition: stroke-dashoffset 2.6s var(--ease) 0.9s;
}
body.is-loaded .hero-arc-path { stroke-dashoffset: 0; }

.scroll-cue {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  flex-direction: column;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: 0.78rem;
  color: var(--cream-soft);
}
.scroll-cue i {
  position: relative;
  width: 1px;
  height: 42px;
  background: rgba(226, 201, 143, 0.25);
  overflow: hidden;
}
.scroll-cue i::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  top: 0;
  height: 40%;
  background: var(--gold-hi);
  animation: cue 2.2s var(--ease-io) infinite;
}
@keyframes cue { 0% { transform: translateY(-100%); } 100% { transform: translateY(260%); } }

/* ---------- Marquee ---------- */
.marquee {
  position: relative;
  overflow: hidden;
  padding-block: 14px;
  background: var(--night);
  border-block: 1px solid var(--line-dark);
}
.marquee-track { display: flex; width: max-content; animation: marquee 38s linear infinite; }
[dir="rtl"] .marquee-track { animation-name: marqueeRtl; }
.marquee-group { display: flex; align-items: center; gap: 28px; padding-inline-end: 28px; flex-shrink: 0; }
.marquee-group span {
  font-family: var(--f-head);
  font-size: clamp(0.82rem, 1vw, 0.95rem);
  font-weight: 300;
  white-space: nowrap;
  color: var(--cream);
}
html[lang="en"] .marquee-group span { letter-spacing: 0.18em; text-transform: uppercase; font-size: 0.72rem; }
.marquee-group b {
  width: 5px;
  height: 5px;
  border: 1px solid var(--gold);
  transform: rotate(45deg);
  opacity: 0.8;
}
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes marqueeRtl { to { transform: translateX(50%); } }

/* ---------- About: the arch portal ---------- */
.portal {
  --p: 0;  /* arch opening */
  --q: 0;  /* statement */
  --v: 0;  /* values */
  position: relative;
  height: 330vh;
  background: var(--paper);
  color: var(--ink);
}
.portal-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  display: grid;
  place-items: center;
}
.portal-word {
  position: absolute;
  left: 50%;
  top: 50%;
  margin: 0;
  transform: translate(-50%, -50%) scale(calc(1 + var(--p) * 0.6));
  font-family: var(--f-wide);
  font-weight: 200;
  font-size: clamp(3rem, 13vw, 13rem);
  letter-spacing: 0.14em;
  text-indent: 0.14em;
  line-height: 1;
  white-space: nowrap;
  direction: ltr;
  color: transparent;
  -webkit-text-stroke: 1px rgba(138, 106, 51, 0.5);
  opacity: calc(1 - var(--p) * 1.8);
  pointer-events: none;
}
.portal-eyebrow {
  position: absolute;
  top: calc(var(--header-h) + 24px);
  left: 50%;
  margin: 0;
  transform: translateX(-50%);
  opacity: calc(1 - var(--p) * 3);
}
.portal-arch {
  --w0: min(30vw, 360px);
  --h0: min(56vh, 500px);
  position: absolute;
  left: 50%;
  top: 50%;
  width: calc(var(--w0) + (100vw - var(--w0)) * var(--p));
  height: calc(var(--h0) + (100% - var(--h0)) * var(--p));
  transform: translate(-50%, calc(-50% + 3vh * (1 - var(--p))));
  /* an arch while framed; it eases to square as the photo fills the screen */
  border-radius:
    calc((1 - var(--p)) * 600px) calc((1 - var(--p)) * 600px)
    calc((1 - var(--p)) * 18px) calc((1 - var(--p)) * 18px);
  overflow: hidden;
  background: var(--navy);
  box-shadow: 0 50px 90px -50px rgba(31, 42, 60, 0.6);
}
.portal-arch img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(calc(1.4 - var(--p) * 0.4));
}
.portal-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(70% 60% at 50% 45%, rgba(23, 21, 14, 0.55), rgba(23, 21, 14, 0.88)),
    linear-gradient(180deg, rgba(23, 21, 14, 0.3), rgba(23, 21, 14, 0.7));
  opacity: calc(0.15 + var(--q) * 0.85);
}
.portal-copy {
  position: relative;
  z-index: 2;
  width: min(100% - 2 * var(--gutter), 1080px);
  text-align: center;
  opacity: var(--q);
  transform: translateY(calc((1 - var(--q)) * 50px));
  visibility: visible;
}
.portal-statement {
  font-family: var(--f-head);
  font-weight: 300;
  font-size: clamp(1.2rem, 2.1vw, 1.95rem);
  line-height: 1.55;
  color: var(--cream);
}
html[lang="en"] .portal-statement { line-height: 1.4; }
.portal-values {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 3vw, 48px);
  margin-top: clamp(36px, 6vh, 64px);
  padding-top: clamp(24px, 4vh, 36px);
  border-top: 1px solid rgba(226, 201, 143, 0.28);
  opacity: var(--v);
  transform: translateY(calc((1 - var(--v)) * 30px));
}
.portal-values h3 {
  font-family: var(--f-head);
  font-weight: 400;
  font-size: clamp(0.98rem, 1.2vw, 1.15rem);
  color: var(--gold-hi);
  margin-bottom: 6px;
}
.portal-values p { font-size: 0.86rem; color: var(--cream-soft); }
.portal-hint {
  position: absolute;
  bottom: 28px;
  left: 50%;
  margin: 0;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 10px;
  font-size: 0.78rem;
  color: var(--ink-soft);
  opacity: calc(1 - var(--p) * 4);
}
.portal-hint i {
  position: relative;
  width: 1px;
  height: 38px;
  background: rgba(31, 42, 60, 0.15);
  overflow: hidden;
}
.portal-hint i::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  top: 0;
  height: 40%;
  background: var(--gold);
  animation: cue 2.2s var(--ease-io) infinite;
}
/* static fallback (reduced motion) */
.portal.is-static { --p: 1; --q: 1; --v: 1; height: auto; }
.portal.is-static .portal-sticky { position: relative; height: auto; min-height: 100vh; padding-block: 140px; }
.portal.is-static .portal-arch { height: 100%; }

[data-split] .w { opacity: 0.16; transition: opacity 0.4s ease; }
[data-split] .w.on { opacity: 1; }

/* ---------- Services: horizontal scroll ---------- */
.works { position: relative; background: var(--olive); }
.works-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}
.works-ghost {
  position: absolute;
  top: 50%;
  left: 0;
  margin: 0;
  transform: translate3d(var(--gx, 0px), -50%, 0);
  font-family: var(--f-head);
  font-weight: 200;
  font-size: clamp(4.5rem, 10vw, 9.5rem);
  line-height: 1;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(226, 201, 143, 0.13);
  pointer-events: none;
  will-change: transform;
}
html[lang="en"] .works-ghost { font-style: italic; }
.works-track {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: clamp(36px, 4vw, 64px);
  padding-inline: var(--gutter);
  width: max-content;
  will-change: transform;
}
.works-intro { width: min(84vw, 620px); flex-shrink: 0; padding-inline-end: clamp(10px, 3vw, 40px); }
.works-intro .h2 { margin-bottom: 24px; }
.works-lead { color: var(--cream-soft); max-width: 26rem; margin-bottom: 36px; }
.works-hint { display: inline-flex; align-items: center; gap: 14px; font-size: 0.85rem; color: var(--gold-hi); }
.works-hint i { animation: nudge 1.8s var(--ease-io) infinite; }
@keyframes nudge { 50% { width: 54px; } }

.work-card {
  position: relative;
  flex-shrink: 0;
  width: min(80vw, 400px);
  height: min(68vh, 600px);
  isolation: isolate;
}
.work-card:nth-of-type(odd) { transform: translateY(-26px); }
.work-card:nth-of-type(even) { transform: translateY(26px); }
.work-card::before {
  content: "";
  position: absolute;
  inset: -12px;
  border: 1px solid rgba(226, 201, 143, 0.28);
  border-radius: 999px 999px 28px 28px;
  pointer-events: none;
  transition: inset 0.8s var(--ease), border-color 0.5s;
}
.work-card:hover::before { inset: -20px; border-color: rgba(226, 201, 143, 0.7); }
/* the whole card opens its service page */
.work-cover { position: absolute; inset: 0; z-index: 1; border-radius: 999px 999px 20px 20px; cursor: pointer; }
.work-card .work-body { z-index: 2; pointer-events: none; }
.work-card .work-body a { pointer-events: auto; }
.work-media {
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: 999px 999px 20px 20px;
  overflow: hidden;
  background: var(--navy);
}
.work-media img {
  position: absolute;
  top: 0;
  left: -12%;
  width: 124%;
  max-width: none;
  height: 100%;
  object-fit: cover;
  transform: translate3d(var(--ix, 0px), 0, 0) scale(var(--s, 1.06));
  transition: transform 1.2s var(--ease), filter 1s;
  filter: saturate(0.75) brightness(0.8);
}
.work-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(23, 21, 14, 0) 30%, rgba(23, 21, 14, 0.94) 86%);
}
.work-card:hover .work-media img { --s: 1; filter: saturate(1) brightness(0.9); }

.work-body {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  padding: clamp(24px, 3vw, 36px);
}
.work-cat {
  display: inline-block;
  padding: 6px 14px;
  border: 1px solid rgba(226, 201, 143, 0.4);
  border-radius: 999px;
  font-size: 0.75rem;
  color: var(--gold-hi);
  margin-bottom: 16px;
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.work-body h3 {
  font-family: var(--f-head);
  font-weight: 400;
  font-size: clamp(1.15rem, 1.6vw, 1.45rem);
  line-height: 1.3;
  margin-bottom: 10px;
}
.work-body p { color: var(--cream-soft); font-size: 0.88rem; margin-bottom: 16px; }
.tags { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-bottom: 20px; }
.tags li { font-size: 0.8rem; color: var(--cream); position: relative; padding-inline-start: 14px; }
.tags li::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: 50%;
  width: 5px;
  height: 5px;
  margin-top: -2px;
  background: var(--gold);
  transform: rotate(45deg);
}
@media (hover: hover) {
  .work-body .tags, .work-body .link-arrow {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.5s ease, transform 0.7s var(--ease);
  }
  .work-card:hover .work-body .tags,
  .work-card:hover .work-body .link-arrow,
  .work-card:focus-within .work-body .tags,
  .work-card:focus-within .work-body .link-arrow { opacity: 1; transform: none; }
  .work-card:hover .work-body .link-arrow { transition-delay: 0.08s; }
}

.works-progress {
  position: absolute;
  bottom: 36px;
  inset-inline: var(--gutter);
  height: 1px;
  background: var(--line-dark);
}
.works-progress span {
  position: absolute;
  inset-block: 0;
  inset-inline-start: 0;
  width: 100%;
  background: var(--grad-gold);
  transform: scaleX(var(--p, 0));
  transform-origin: left;
}
[dir="rtl"] .works-progress span { transform-origin: right; }

/* ---------- Consulting: arch accordion ---------- */
.consulting { background: var(--navy); overflow: hidden; }
.consulting::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(45% 55% at 50% 100%, rgba(184, 151, 90, 0.16), transparent 70%);
}
.consulting .container { position: relative; }
.consulting-lead { color: var(--cream-soft); max-width: 26rem; }

.arches {
  display: flex;
  gap: 14px;
  height: clamp(500px, 66vh, 620px);
}
.arch-panel {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  overflow: hidden;
  isolation: isolate;
  border-radius: 999px 999px 20px 20px;
  border: 1px solid rgba(226, 201, 143, 0.2);
  background: var(--navy-2);
  transition: flex-grow 1s var(--ease), border-color 0.5s;
}
.arch-panel:hover { border-color: rgba(226, 201, 143, 0.45); }
.arch-panel.is-open { flex-grow: 4.2; border-color: rgba(226, 201, 143, 0.6); }

.arch-bg { position: absolute; inset: 0; z-index: -1; }
.arch-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.16;
  filter: grayscale(0.6);
  transform: scale(1.18);
  transition: opacity 0.9s ease, transform 1.6s var(--ease), filter 0.9s;
}
.arch-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(23, 33, 49, 0.15) 0%, rgba(23, 33, 49, 0.55) 45%, rgba(23, 33, 49, 0.96) 78%);
}
.arch-panel.is-open .arch-bg img { opacity: 0.7; filter: none; transform: scale(1); }

.arch-trigger {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  padding-bottom: 34px;
  transition: opacity 0.4s ease;
}
.arch-trigger::before {
  content: "";
  width: 7px;
  height: 7px;
  background: var(--gold);
  transform: rotate(45deg);
  order: 2;
}
.arch-vtitle {
  writing-mode: vertical-rl;
  font-family: var(--f-head);
  font-weight: 300;
  font-size: 1rem;
  line-height: 1;
  color: var(--cream);
  white-space: nowrap;
}
.arch-panel.is-open .arch-trigger { opacity: 0; pointer-events: none; }

.arch-content {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  z-index: 1;
  min-width: 380px;
  padding: clamp(26px, 3vw, 44px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(24px);
  transition: opacity 0.4s ease, transform 0.6s var(--ease), visibility 0s 0.4s;
}
.arch-panel.is-open .arch-content {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.7s ease 0.35s, transform 1s var(--ease) 0.35s, visibility 0s;
}
.arch-ico {
  width: 54px;
  height: 54px;
  fill: none;
  stroke: var(--gold-hi);
  stroke-width: 1.3;
  stroke-linecap: round;
  stroke-linejoin: round;
  margin-bottom: 18px;
}
.arch-ico path { stroke-dasharray: 1; stroke-dashoffset: 1; }
.arch-panel.is-open .arch-ico path { stroke-dashoffset: 0; transition: stroke-dashoffset 1.8s var(--ease) 0.45s; }
.arch-content h3 {
  font-family: var(--f-head);
  font-weight: 300;
  font-size: clamp(1.25rem, 1.8vw, 1.6rem);
  line-height: 1.3;
  margin-bottom: 10px;
}
.arch-content p { color: var(--cream-soft); max-width: 25rem; margin-bottom: 18px; }

/* ---------- Gallery: photos-app grid ---------- */
.gallery { background: var(--paper); color: var(--ink); }
.gallery-head {
  display: grid;
  justify-items: center;
  text-align: center;
  margin-bottom: clamp(36px, 5vw, 56px);
}
.gallery-hint { margin-top: 14px; font-size: 0.9rem; color: var(--ink-soft); }

.seg {
  position: relative;
  display: inline-flex;
  max-width: 100%;
  margin-top: 28px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(31, 42, 60, 0.05);
  border: 1px solid var(--line-light);
  overflow-x: auto;
  scrollbar-width: none;
}
.seg::-webkit-scrollbar { display: none; }
.seg-ink {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 0;
  right: auto;
  border-radius: 999px;
  background: var(--navy);
  box-shadow: 0 8px 18px -10px rgba(31, 42, 60, 0.7);
  transition: transform 0.55s var(--ease), width 0.55s var(--ease);
}
.seg-btn {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  padding: 9px 20px;
  border-radius: 999px;
  font-size: 0.85rem;
  white-space: nowrap;
  color: var(--ink-soft);
  transition: color 0.4s ease;
}
.seg-btn:hover { color: var(--ink); }
.seg-btn.is-active { color: var(--paper); }

.photos {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-auto-flow: dense;
  gap: 4px;
  border-radius: 24px;
  overflow: hidden;
}
.ph {
  position: relative;
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--stone);
  cursor: zoom-in;
}
.ph[hidden] { display: none; }
.ph--big { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }
.ph img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.ph::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(23, 21, 14, 0.4));
  opacity: 0;
  transition: opacity 0.5s ease;
}
.ph:hover img { transform: scale(1.06); }
.ph:hover::after { opacity: 1; }
.ph:focus-visible { outline: 2px solid var(--gold); outline-offset: -2px; border-radius: 0; }
.ph.is-source { visibility: hidden; }

/* ---------- Quote ---------- */
.quote { background: var(--night); overflow: hidden; }
.quote::after {
  content: "";
  position: absolute;
  inset-inline-end: -10%;
  top: 50%;
  width: 60vw;
  height: 60vw;
  transform: translateY(-50%);
  border-radius: 50%;
  border: 1px solid var(--line-dark);
  pointer-events: none;
}
.quote-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.4fr);
  gap: clamp(40px, 7vw, 120px);
  align-items: center;
}
.portrait { position: relative; }
.portrait::before {
  content: "";
  position: absolute;
  inset: -14px;
  border: 1px solid rgba(226, 201, 143, 0.35);
  border-radius: 12px;
}
.portrait-arch {
  position: relative;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 18px;
  aspect-ratio: 3 / 4;
  border-radius: 12px;
  overflow: hidden;
  background:
    radial-gradient(70% 50% at 50% 30%, rgba(184, 151, 90, 0.22), transparent 70%),
    linear-gradient(180deg, var(--olive-2), var(--navy-2));
}
.portrait-arch img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.portrait-mark { width: 40%; aspect-ratio: 130 / 84; color: var(--gold); opacity: 0.35; }
.portrait-note { font-size: 0.78rem; color: var(--cream-soft); letter-spacing: 0.04em; }

.quote-block { position: relative; }
.quote-glyph {
  position: absolute;
  top: -0.42em;
  inset-inline-start: -0.08em;
  font-family: var(--f-serif);
  font-size: clamp(6.5rem, 11vw, 10rem);
  line-height: 1;
  background: var(--grad-gold);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  opacity: 0.4;
  pointer-events: none;
}
.quote-text {
  position: relative;
  font-family: var(--f-head);
  font-weight: 300;
  font-size: clamp(1.35rem, 2.4vw, 2.2rem);
  line-height: 1.55;
  color: var(--cream);
  margin-bottom: 44px;
}
html[lang="en"] .quote-text { font-style: italic; line-height: 1.4; }
.quote-cite { display: flex; align-items: center; gap: 20px; }
.cite-rule { width: 56px; height: 1px; background: var(--grad-gold); flex-shrink: 0; }
.quote-cite cite { font-style: normal; font-size: 1rem; color: var(--gold-hi); line-height: 1.6; }
.quote-cite small { display: block; font-size: 0.82rem; color: var(--cream-soft); }

/* ---------- Advisors ---------- */
.advisors { background: var(--paper); color: var(--ink); }
.advisors-note { max-width: 25rem; font-size: 0.92rem; color: var(--ink-soft); }
.adv-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; }
.adv-card {
  position: relative;
  border-radius: 999px 999px var(--radius) var(--radius);
  background: #fbfaf6;
  border: 1px solid var(--line-light);
  padding: 12px 12px 28px;
  transform-style: preserve-3d;
  transition: box-shadow 0.6s var(--ease), border-color 0.4s;
}
.adv-card:hover { box-shadow: 0 30px 60px -30px rgba(31, 42, 60, 0.35); border-color: rgba(184, 151, 90, 0.5); }
.adv-photo {
  position: relative;
  aspect-ratio: 1 / 1.08;
  border-radius: 999px 999px 12px 12px;
  background: linear-gradient(180deg, var(--olive), var(--night));
  margin-bottom: 22px;
  overflow: hidden;
}
.adv-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.7) brightness(0.85);
  transform: scale(1.06);
  transition: transform 1.2s var(--ease), filter 0.8s;
}
.adv-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(23, 21, 14, 0) 45%, rgba(23, 21, 14, 0.75) 100%);
}
.adv-photo svg {
  position: absolute;
  z-index: 1;
  left: 50%;
  bottom: 16px;
  width: 54px;
  aspect-ratio: 130 / 84;
  transform: translateX(-50%);
  color: var(--gold-hi);
  opacity: 0.9;
}
.adv-card:hover .adv-photo img { transform: scale(1); filter: saturate(1) brightness(0.95); }
.adv-body { padding-inline: 14px; }
.adv-field { font-size: 0.74rem; color: var(--gold-lo); margin-bottom: 6px; }
.adv-body h3 { font-family: var(--f-head); font-weight: 500; font-size: 1.02rem; margin-bottom: 8px; line-height: 1.4; }
html[lang="en"] .adv-body h3 { font-weight: 400; font-size: 1.15rem; }
.adv-body p { font-size: 0.88rem; color: var(--ink-soft); margin-bottom: 16px; }
.adv-soon {
  display: inline-block;
  font-size: 0.72rem;
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(184, 151, 90, 0.12);
  color: var(--gold-lo);
}

/* ---------- Contact ---------- */
.contact { background: var(--olive); }
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.2fr);
  gap: clamp(40px, 7vw, 120px);
  align-items: start;
}
.contact-info .h2 { margin-bottom: 24px; }
.contact-lead { color: var(--cream-soft); max-width: 26rem; margin-bottom: 48px; }
.contact-list { display: grid; gap: 22px; border-top: 1px solid var(--line-dark); padding-top: 28px; }
.contact-list dt { font-size: 0.76rem; color: var(--gold); margin-bottom: 2px; }
.contact-list dd { font-size: 1.05rem; color: var(--cream); }
[dir="rtl"] .contact-list dd[dir="ltr"] { text-align: right; }

.form {
  position: relative;
  display: grid;
  gap: 26px;
  padding: clamp(28px, 4vw, 52px);
  border-radius: calc(var(--radius) + 8px);
  background: linear-gradient(160deg, rgba(53, 49, 31, 0.9), rgba(23, 21, 14, 0.9));
  border: 1px solid var(--line-dark);
}
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px; }
.field { position: relative; }
.field input, .field textarea, .field select {
  width: 100%;
  padding: 26px 0 10px;
  border: 0;
  border-bottom: 1px solid rgba(226, 201, 143, 0.28);
  background: transparent;
  color: var(--cream);
  font-family: var(--f-body);
  font-size: 1rem;
  font-weight: 300;
  border-radius: 0;
  transition: border-color 0.4s;
}
[dir="rtl"] .field input[dir="ltr"] { text-align: right; }
.field textarea { resize: vertical; min-height: 110px; }
.field select { appearance: none; -webkit-appearance: none; cursor: pointer; }
.field select option { background: var(--olive); color: var(--cream); }
.field-select::after {
  content: "";
  position: absolute;
  inset-inline-end: 4px;
  top: 32px;
  width: 8px;
  height: 8px;
  border-right: 1px solid var(--gold);
  border-bottom: 1px solid var(--gold);
  transform: rotate(45deg);
  pointer-events: none;
}
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--gold-hi); }
.field label {
  position: absolute;
  inset-inline-start: 0;
  top: 26px;
  font-size: 1rem;
  color: var(--cream-soft);
  pointer-events: none;
  transform-origin: var(--lbl-origin, left) top;
  transition: transform 0.4s var(--ease), color 0.3s;
}
[dir="rtl"] .field label { transform-origin: right top; }
.field input:focus + label,
.field input:not(:placeholder-shown) + label,
.field textarea:focus + label,
.field textarea:not(:placeholder-shown) + label,
.field-select label { transform: translateY(-24px) scale(0.78); color: var(--gold); }

.field-error { display: none; margin-top: 8px; font-size: 0.8rem; color: #e8a07a; }
.field.has-error input, .field.has-error textarea { border-color: #e8a07a; }
.field.has-error .field-error, .check.has-error .field-error { display: block; }

.check { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: start; }
.check input {
  appearance: none;
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  margin: 4px 0 0;
  border: 1px solid rgba(226, 201, 143, 0.5);
  border-radius: 6px;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background-color 0.3s;
}
.check input::after {
  content: "";
  width: 5px;
  height: 10px;
  border-right: 2px solid var(--night);
  border-bottom: 2px solid var(--night);
  transform: rotate(45deg) scale(0);
  margin-top: -2px;
  transition: transform 0.3s var(--ease);
}
.check input:checked { background: var(--gold); border-color: var(--gold); }
.check input:checked::after { transform: rotate(45deg) scale(1); }
.check label { font-size: 0.88rem; color: var(--cream-soft); cursor: pointer; }
.check .field-error { grid-column: 2; margin-top: 0; }

.hp-field { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; inset-inline-start: -9999px; }

.form-success {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 8px;
  padding: 32px;
  text-align: center;
  border-radius: inherit;
  background: var(--night);
  animation: fadeIn 0.6s ease;
}
.form-success[hidden] { display: none; }
.form-success svg { width: 64px; height: 64px; fill: none; stroke: var(--gold); stroke-width: 1.5; margin-bottom: 10px; }
.form-success circle { stroke-dasharray: 140; stroke-dashoffset: 140; animation: lmDraw 1s var(--ease) forwards; }
.form-success path { stroke-dasharray: 40; stroke-dashoffset: 40; animation: lmDraw 0.6s var(--ease) 0.6s forwards; }
.fs-title { font-family: var(--f-head); font-size: 1.45rem; color: var(--gold-hi); }
.form-success p:last-child { color: var(--cream-soft); }
@keyframes fadeIn { from { opacity: 0; } }

/* ---------- Photo viewer ---------- */
.viewer { position: fixed; inset: 0; z-index: 450; }
.viewer[hidden] { display: none; }
.viewer-bg { position: absolute; inset: 0; background: #0e0d08; }
.viewer-stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
  touch-action: none;
  cursor: zoom-in;
}
.viewer.is-zoomed .viewer-stage { cursor: grab; }
.viewer.is-zoomed.is-dragging .viewer-stage { cursor: grabbing; }
.viewer-img {
  position: absolute;
  max-width: none;
  border-radius: 4px;
  transform-origin: center;
  will-change: transform;
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

.viewer-top, .viewer-bottom, .v-nav {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}
.viewer.is-open:not(.chrome-off):not(.is-dragging) .viewer-top,
.viewer.is-open:not(.chrome-off):not(.is-dragging) .viewer-bottom,
.viewer.is-open:not(.chrome-off):not(.is-dragging) .v-nav { opacity: 1; pointer-events: auto; }
.viewer.is-zoomed .viewer-bottom, .viewer.is-zoomed .v-nav { opacity: 0 !important; pointer-events: none !important; }

.viewer-top {
  position: absolute;
  top: 0;
  inset-inline: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 76px;
  padding-inline: var(--gutter);
  background: linear-gradient(180deg, rgba(14, 13, 8, 0.75), transparent);
}
.v-count {
  font-family: var(--f-wide);
  font-size: 0.8rem;
  letter-spacing: 0.24em;
  color: var(--cream-soft);
  direction: ltr;
}
.v-zoom { display: flex; gap: 8px; }

.v-btn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(226, 201, 143, 0.22);
  background: rgba(23, 21, 14, 0.45);
  color: var(--cream);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  transition: border-color 0.3s, color 0.3s, background-color 0.3s;
}
.v-btn:hover { border-color: var(--gold); color: var(--gold-hi); }
.v-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

.v-nav {
  position: absolute;
  top: 50%;
  z-index: 2;
  width: 52px;
  height: 52px;
  margin-top: -50px;
}
.v-prev { inset-inline-start: clamp(14px, 2.4vw, 32px); }
.v-next { inset-inline-end: clamp(14px, 2.4vw, 32px); }
[dir="rtl"] .v-nav svg { transform: scaleX(-1); }
.viewer.is-open:not(.chrome-off):not(.is-dragging) .v-nav:disabled { opacity: 0.2; pointer-events: none; }

.viewer-bottom {
  position: absolute;
  bottom: 0;
  inset-inline: 0;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 14px;
  padding: 18px var(--gutter) 22px;
  background: linear-gradient(0deg, rgba(14, 13, 8, 0.85), transparent);
}
.v-caption { display: grid; gap: 2px; text-align: center; }
.v-caption span { font-size: 0.72rem; color: var(--gold); }
.v-caption strong { font-family: var(--f-head); font-weight: 300; font-size: 1.05rem; color: var(--cream); }

.v-strip {
  display: flex;
  gap: 6px;
  max-width: min(100%, 680px);
  padding: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}
.v-strip::-webkit-scrollbar { display: none; }
.v-thumb {
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  border-radius: 8px;
  overflow: hidden;
  opacity: 0.4;
  outline: 1px solid transparent;
  outline-offset: 2px;
  transition: opacity 0.3s ease, transform 0.4s var(--ease), outline-color 0.3s;
}
.v-thumb:hover { opacity: 0.75; }
.v-thumb.is-active { opacity: 1; transform: scale(1.08); outline-color: var(--gold); }
.v-thumb img { width: 100%; height: 100%; object-fit: cover; }

@media (max-width: 700px) {
  .viewer-top { height: 64px; }
  .v-nav, .v-zoom { display: none; }
  .v-thumb { width: 40px; height: 40px; }
}

/* ---------- Footer ---------- */
.footer { background: var(--night); padding-top: clamp(64px, 9vw, 110px); overflow: hidden; }
.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 28px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--line-dark);
}
.footer-nav { display: flex; flex-wrap: wrap; gap: 14px 30px; }
.footer-nav a { font-size: 0.9rem; color: var(--cream-soft); transition: color 0.3s; }
.footer-nav a:hover { color: var(--gold-hi); }
.footer-word {
  font-family: var(--f-wide);
  font-weight: 200;
  font-size: clamp(2.6rem, 11vw, 11rem);
  letter-spacing: 0.16em;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  margin-block: clamp(36px, 6vw, 70px);
  margin-inline-end: -0.16em;
  background: linear-gradient(180deg, var(--gold-hi), rgba(138, 106, 51, 0.15));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  direction: ltr;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  padding-block: 26px;
  border-top: 1px solid var(--line-dark);
  font-size: 0.82rem;
  color: var(--cream-soft);
}
.to-top { display: inline-flex; align-items: center; gap: 12px; color: var(--gold-hi); }
.to-top i { width: 1px; height: 22px; }
.to-top i::after { inset-inline-end: auto; left: -4px; top: 0; transform: rotate(-45deg); }

/* ---------- Scroll reveals ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(46px);
  transition: opacity 1s ease, transform 1.2s var(--ease);
  transition-delay: calc(var(--d, 0) * 0.1s);
}
[data-reveal].is-in { opacity: 1; transform: none; }
/* mask: a curtain in the section color lifts off the image */
[data-reveal="mask"] { opacity: 1; transform: none; }
[data-reveal="mask"]::after {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: 2;
  background: var(--mask-c, var(--paper));
  transform-origin: top;
  transition: transform 1.5s var(--ease-io);
}
[data-reveal="mask"].is-in::after { transform: scaleY(0); }
[data-reveal="mask"] > img { transform: scale(1.18); transition: transform 2.2s var(--ease); }
[data-reveal="mask"].is-in > img { transform: scale(1); }
.portrait-arch[data-reveal="mask"] { --mask-c: var(--night); }

/* Headings stay on one line on larger screens */
@media (min-width: 901px) {
  .h2, .hero-title { white-space: nowrap; }
}
/* on phones the size follows the screen width so the line still fits */
@media (max-width: 900px) {
  .h2, .consulting-head .h2 { white-space: nowrap; font-size: min(5.4vw, 2.2rem); }
  .hero-title { white-space: nowrap; font-size: min(9.5vw, 3rem); }
  html[lang="en"] .hero-title { font-size: min(6.2vw, 3rem); }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .photos { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3px; border-radius: 16px; }
  .seg-btn { padding: 8px 12px; font-size: 0.78rem; }
}

@media (max-width: 1100px) {
  .nav { display: none; }
  .menu-toggle { display: block; }
  .adv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  :root { --header-h: 72px; }
  .header-actions .btn { display: none; }
  .hero-pins { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding-inline: 10px; }
  .pin-col:nth-child(n + 4) { display: none; }
  .hero-copy .eyebrow { font-size: 0.74rem; gap: 10px; }
  .hero-copy .eyebrow::before, .hero-copy .eyebrow::after { width: 18px; flex-shrink: 0; }
  .hero-veil {
    background:
      radial-gradient(80% 50% at 50% 50%, rgba(42, 39, 28, 0.94), rgba(42, 39, 28, 0.6)),
      linear-gradient(180deg, rgba(42, 39, 28, 0.9) 0%, transparent 25%, transparent 75%, var(--olive) 100%);
  }
  .hero-arc { height: 40%; }
  .quote-grid, .contact-grid { grid-template-columns: 1fr; }
  .portrait { max-width: 300px; margin-inline: auto; }
  .quote-glyph { font-size: 5.5rem; }

  /* About portal */
  .portal { height: 280vh; }
  .portal-arch { --w0: min(64vw, 300px); --h0: min(50vh, 420px); }
  .portal-values { grid-template-columns: 1fr; gap: 14px; }
  .portal-values li { display: grid; grid-template-columns: 7.5rem 1fr; gap: 12px; text-align: start; align-items: baseline; }
  .portal-values h3 { margin: 0; }

  /* Services become a vertical stack */
  .works { height: auto !important; padding-block: 96px; }
  .works-sticky { position: static; height: auto; overflow: visible; }
  .works-ghost { display: none; }
  .works-track { flex-direction: column; align-items: stretch; width: 100%; transform: none !important; gap: 44px; }
  .works-intro { width: 100%; padding: 0 0 12px; }
  .works-hint, .works-progress { display: none; }
  .work-card, .work-card:nth-of-type(odd), .work-card:nth-of-type(even) {
    width: calc(100% - 24px);
    margin-inline: auto;
    height: auto;
    aspect-ratio: 4 / 5.4;
    max-height: 620px;
    transform: none;
  }
  .work-media img { left: 0; width: 100%; transform: none; }

  /* Consulting: vertical accordion */
  .arches { flex-direction: column; height: auto; gap: 12px; }
  .arch-panel { flex: none; height: 76px; border-radius: 999px; transition: height 0.9s var(--ease), border-radius 0.9s var(--ease), border-color 0.5s; }
  .arch-panel.is-open { height: 470px; border-radius: 220px 220px 20px 20px; }
  .arch-trigger { flex-direction: row; justify-content: space-between; align-items: center; padding: 0 30px; }
  .arch-trigger::before { order: 2; }
  .arch-vtitle { writing-mode: horizontal-tb; font-size: 0.98rem; }
  .arch-content { min-width: 0; }
}

@media (max-width: 600px) {
  .form-row { grid-template-columns: 1fr; }
  .adv-grid { grid-template-columns: 1fr; max-width: 360px; margin-inline: auto; }
  .brand-text { display: none; }
  .hero-actions .btn { flex: 1 1 100%; }
  .portal-values p { font-size: 0.82rem; }
  .portal-values li { grid-template-columns: 6rem 1fr; }
  .footer-top { justify-content: center; text-align: center; }
  .footer-nav { justify-content: center; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    transition-delay: 0s !important;
  }
  .pin-track, .marquee-track { animation: none !important; }
  [data-reveal], [data-reveal="mask"] { opacity: 1; transform: none; clip-path: none; }
  [data-split] .w { opacity: 1; }
}
