/* =========================================================================
   GLENGARRA — Homepage prototype
   Design system: "The Editorial Advisor" (governing) + "The Precision
   Instrument" (evidence/method layer).
   NOTE: Tiempos Headline here is the supplied TEST cut, used for visual
   reference only. Production requires properly licensed webfont files.
   ========================================================================= */

/* ---------- Fonts ---------- */
@font-face {
  font-family: "Tiempos Headline";
  src: url("../assets/fonts/TiemposHeadline-Light.otf") format("opentype");
  font-weight: 300; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Tiempos Headline";
  src: url("../assets/fonts/TiemposHeadline-Regular.otf") format("opentype");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Tiempos Headline";
  src: url("../assets/fonts/TiemposHeadline-Medium.otf") format("opentype");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../assets/fonts/Inter-Light.ttf") format("truetype");
  font-weight: 300; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../assets/fonts/Inter-Regular.ttf") format("truetype");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../assets/fonts/Inter-Medium.ttf") format("truetype");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../assets/fonts/Inter-SemiBold.ttf") format("truetype");
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../assets/fonts/Inter-Bold.ttf") format("truetype");
  font-weight: 700; font-style: normal; font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  /* Brand colour (from Glengarra Brand Guidelines) */
  --lime:        #C6F351;
  --forest:      #124A2C;
  --forest-deep: #0E3A22;
  --forest-line: #1E5C3A;
  --aubergine:   #561B49;
  --brown:       #433226;

  /* Editorial neutrals */
  --bone:        #F4F1E9;
  --bone-2:      #ECE7DB;
  --bone-3:      #E2DCCC;
  --ink:         #16201A;   /* warm near-black */
  --ink-soft:    #43514A;
  --ink-faint:   #6E7A72;

  /* Semantic (light default) */
  --bg:          var(--bone);
  --fg:          var(--ink);
  --fg-soft:     var(--ink-soft);
  --fg-faint:    var(--ink-faint);
  --rule:        rgba(22, 32, 26, 0.14);
  --accent:      var(--forest);

  /* Type */
  --serif: "Tiempos Headline", Georgia, "Times New Roman", serif;
  --sans:  "Inter", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;

  /* Rhythm. ONE fluid editorial canvas, shared by every section on every
     page — not a narrow/wide pair selected per section. Floor (1280px)
     is the protected laptop-safe value: clamp()'s minimum branch keeps
     the canvas at exactly 1280px for every viewport up to 1500px, so
     1280/1366/1440/tablet/mobile are byte-identical to before. From
     1500px the canvas grows continuously (no snap) to a 1960px ceiling
     on large monitors, then holds — never edge-to-edge. Canvas width is
     deliberately NOT how paragraph line-length is controlled: that is
     the job of .measure/.measure-sm/.measure-xs (below) on the text
     component itself, so prose stays readable while the canvas around
     it grows. */
  --container: clamp(1280px, calc(1280px + 1.6 * (100vw - 1500px)), 1960px);
  --gutter: clamp(1.25rem, 4vw, 4.5rem);
  --section-y: clamp(4.5rem, 9vw, 9rem);
  --radius: 2px;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Reset-ish ---------- */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-weight: 400;
  font-size: clamp(1rem, 0.55vw + 0.9rem, 1.125rem);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
h1,h2,h3,h4 { margin: 0; font-weight: 400; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section-y); position: relative; }
.section--tight { padding-block: clamp(3rem, 6vw, 5.5rem); }

.theme-dark      { --bg: var(--forest);      --fg: var(--bone); --fg-soft: #C6D3C6; --fg-faint: #8FA592; --rule: rgba(255,255,255,0.16); --accent: var(--lime); background: var(--bg); color: var(--fg); }
.theme-forest-deep { --bg: var(--forest-deep); --fg: var(--bone); --fg-soft: #B9C8BC; --fg-faint: #85998A; --rule: rgba(255,255,255,0.14); --accent: var(--lime); background: var(--bg); color: var(--fg); }
.theme-aubergine { --bg: var(--aubergine);   --fg: #F3E9F0; --fg-soft: #D8BCD1; --fg-faint: #B491AC; --rule: rgba(255,255,255,0.16); --accent: var(--lime); background: var(--bg); color: var(--fg); }
.theme-bone-2    { --bg: var(--bone-2); background: var(--bg); }

/* ---------- Typography system ---------- */
/* Original curves, unchanged — this is the protected baseline for every
   width up to the large-desktop layer near the end of this file. */
.display {
  font-family: var(--serif);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.02em;
  font-size: clamp(2.6rem, 6.4vw, 5.4rem);
}
.h-xl { font-family: var(--serif); font-weight: 300; line-height: 1.06; letter-spacing: -0.018em; font-size: clamp(2.1rem, 4.6vw, 3.9rem); }
.h-lg { font-family: var(--serif); font-weight: 300; line-height: 1.1;  letter-spacing: -0.015em; font-size: clamp(1.8rem, 3.4vw, 2.9rem); }
.h-md { font-family: var(--serif); font-weight: 400; line-height: 1.15; letter-spacing: -0.01em;  font-size: clamp(1.35rem, 1.6vw, 1.7rem); }

.lead { font-size: clamp(1.15rem, 1.1vw + 0.9rem, 1.5rem); line-height: 1.5; color: var(--fg-soft); font-weight: 300; }
.body-soft { color: var(--fg-soft); }
.measure { max-width: 62ch; }
.measure-sm { max-width: 46ch; }
.measure-xs { max-width: 34ch; }

/* Eyebrow / small-caps label — the senior "metadata" voice */
.eyebrow {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-faint);
  display: inline-flex;
  align-items: center;
  gap: 0.7em;
}
.eyebrow::before {
  content: "";
  width: 1.6em; height: 1px;
  background: var(--accent);
  display: inline-block;
}
.eyebrow--plain::before { display: none; }
.index-num {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--accent);
}

/* Lime is a precise accent only */
.mark { color: var(--lime); }
.fs-accent { color: var(--accent); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.65em;
  font-family: var(--sans); font-weight: 500; font-size: 0.92rem;
  letter-spacing: 0.01em;
  padding: 0.95em 1.5em;
  border-radius: var(--radius);
  border: 1px solid transparent;
  transition: background .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease), transform .35s var(--ease);
  will-change: transform;
}
.btn .arrow { transition: transform .35s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }
.btn--primary { background: var(--forest); color: var(--bone); }
.btn--primary:hover { background: var(--ink); }
.theme-dark .btn--primary, .theme-forest-deep .btn--primary, .theme-aubergine .btn--primary { background: var(--lime); color: var(--forest-deep); }
.theme-dark .btn--primary:hover, .theme-forest-deep .btn--primary:hover, .theme-aubergine .btn--primary:hover { background: #d7fa73; }
.btn--ghost { border-color: var(--rule); color: var(--fg); background: transparent; }
.btn--ghost:hover { border-color: var(--accent); color: var(--fg); }

/* Text link with underline accent */
.link {
  display: inline-flex; align-items: center; gap: 0.55em;
  font-weight: 500; font-size: 0.92rem;
  padding-bottom: 2px;
  border-bottom: 1px solid var(--accent);
  transition: gap .3s var(--ease);
}
.link:hover { gap: 0.9em; }
.link .arrow { color: var(--accent); }

/* =========================================================================
   HEADER / NAV
   ========================================================================= */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  transition: background .4s var(--ease), border-color .4s var(--ease), backdrop-filter .4s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header__inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 2rem;
  height: 78px;
}
.brand { display: flex; align-items: center; z-index: 2; }
.brand img { height: 26px; width: auto; }
.brand .logo-forest { display: none; }

.nav { display: flex; align-items: center; gap: clamp(1rem, 2vw, 2.1rem); }
.nav__list { display: flex; align-items: center; gap: clamp(1rem, 2vw, 2.1rem); }
.nav__link {
  font-size: 0.9rem; font-weight: 500; letter-spacing: 0.01em;
  color: var(--nav-fg, var(--bone));
  padding: 0.4em 0; position: relative;
  display: inline-flex; align-items: center; gap: 0.4em;
  transition: color .3s var(--ease);
}
.nav__link .caret { width: 9px; height: 9px; transition: transform .3s var(--ease); opacity: .8; }
.nav__item--has-menu:hover .caret { transform: rotate(180deg); }
.nav__link::after {
  content: ""; position: absolute; left: 0; bottom: -2px; height: 1px; width: 0;
  background: var(--lime); transition: width .3s var(--ease);
}
.nav__link:hover::after, .nav__item--has-menu:hover .nav__link::after { width: 100%; }

.nav__cta {
  font-size: 0.9rem; font-weight: 500;
  color: var(--nav-fg, var(--bone));
  border: 1px solid var(--nav-border, rgba(255,255,255,0.28));
  padding: 0.6em 1.1em; border-radius: var(--radius);
  transition: border-color .3s var(--ease), background .3s var(--ease), color .3s var(--ease);
}
.nav__cta:hover { border-color: var(--lime); }

/* Header states */
.site-header[data-state="solid"] {
  background: rgba(244,241,233,0.92);
  backdrop-filter: blur(10px);
  border-bottom-color: var(--rule);
  --nav-fg: var(--ink);
  --nav-border: rgba(22,32,26,0.2);
}
.site-header[data-state="solid"] .brand .logo-lime { display: none; }
.site-header[data-state="solid"] .brand .logo-forest { display: block; }
.site-header[data-state="solid"] .nav__cta:hover { border-color: var(--forest); }
.site-header[data-state="solid"] .nav__link::after { background: var(--forest-line); }

/* Dropdown mega menu */
.nav__item--has-menu { position: relative; }
.megamenu {
  position: absolute; top: calc(100% + 14px); left: 50%; transform: translateX(-50%) translateY(8px);
  width: min(680px, 86vw);
  background: var(--bone); color: var(--ink);
  border: 1px solid var(--rule); border-radius: var(--radius);
  box-shadow: 0 30px 60px -30px rgba(14,40,25,0.45);
  padding: 1.6rem;
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
}
/* Invisible hover bridge: the 14px offset above leaves a dead strip that
   belongs to neither the trigger <li> nor this absolutely-positioned panel,
   so crossing it drops :hover and closes the menu before the cursor
   arrives. This pseudo-element is a descendant of .megamenu (so hovering
   it still satisfies .nav__item--has-menu:hover/:focus-within) and spans
   the full panel width so diagonal movement into either column is caught,
   without changing the panel's visual position. */
.megamenu::before {
  content: ""; position: absolute; top: -14px; left: 0; right: 0; height: 14px;
}
.nav__item--has-menu:hover .megamenu,
.nav__item--has-menu:focus-within .megamenu {
  opacity: 1; visibility: visible; pointer-events: auto; transform: translateX(-50%) translateY(0);
}
.megamenu__label { grid-column: 1 / -1; margin-bottom: 0.4rem; }
.megamenu__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.4rem 1.5rem; }
.mega-item { display: block; padding: 0.85rem 0.9rem; border-radius: var(--radius); transition: background .25s var(--ease); position: relative; }
.mega-item:hover { background: var(--bone-2); }
.mega-item__t { font-family: var(--sans); font-weight: 600; font-size: 0.98rem; display: flex; align-items: center; gap: 0.5em; }
.mega-item__d { font-size: 0.82rem; color: var(--ink-soft); margin-top: 0.2rem; line-height: 1.45; }
.mega-item--primary { grid-column: 1 / -1; background: var(--forest); color: var(--bone); }
.mega-item--primary:hover { background: var(--forest-deep); }
.mega-item--primary .mega-item__d { color: #C6D3C6; }
.mega-item--primary .mega-item__t::after { content: "Centre of Glengarra"; margin-left: auto; font-family: var(--sans); font-weight: 500; font-size: 0.62rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--lime); }
.tier-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--lime); flex: none; }

/* Mobile nav */
.nav-toggle { display: none; }
.mobile-nav { display: none; }

@media (max-width: 900px) {
  .nav { display: none; }
  .nav-toggle {
    display: inline-flex; flex-direction: column; gap: 5px; z-index: 120;
    background: transparent; border: 0; padding: 8px 0;
  }
  .nav-toggle span { width: 26px; height: 2px; background: var(--nav-fg, var(--bone)); transition: transform .35s var(--ease), opacity .35s var(--ease); }
  .site-header[data-state="solid"] .nav-toggle span { background: var(--ink); }
  body.menu-open .nav-toggle span { background: var(--bone); }
  body.menu-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  body.menu-open .nav-toggle span:nth-child(2) { opacity: 0; }
  body.menu-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .mobile-nav {
    display: block; position: fixed; inset: 0; z-index: 110;
    background: var(--forest-deep); color: var(--bone);
    padding: 96px var(--gutter) 3rem;
    transform: translateY(-100%); transition: transform .5s var(--ease);
    overflow-y: auto;
  }
  body.menu-open .mobile-nav { transform: translateY(0); }
  .mobile-nav__list { display: flex; flex-direction: column; }
  .mobile-nav__list > li { border-bottom: 1px solid rgba(255,255,255,0.14); }
  .mobile-nav__link { display: block; padding: 1rem 0; font-family: var(--serif); font-weight: 300; font-size: 1.7rem; letter-spacing: -0.01em; }
  .mobile-sub { padding: 0 0 1rem 0.2rem; display: flex; flex-direction: column; gap: 0.55rem; }
  .mobile-sub a { font-size: 0.98rem; color: #C6D3C6; display: flex; align-items: center; gap: 0.5em; }
  .mobile-sub a .tier-dot { width: 5px; height: 5px; }
  .mobile-nav__foot { margin-top: 2rem; display: flex; flex-direction: column; gap: 1rem; }
}

/* =========================================================================
   HERO
   ========================================================================= */
.hero {
  position: relative; min-height: 100svh; display: flex; align-items: flex-end;
  background: var(--forest-deep); color: var(--bone); overflow: hidden;
  isolation: isolate;
}
.hero__media { position: absolute; inset: 0; z-index: -2; background: var(--forest-deep); }
.hero__media img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.06) brightness(0.62);
  mix-blend-mode: luminosity; opacity: 0.85;
  transform: scale(1.06);
}
.hero__media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(14,40,25,0.55) 0%, rgba(14,40,25,0.35) 40%, rgba(14,40,25,0.82) 100%),
    linear-gradient(90deg, rgba(14,40,25,0.75) 0%, rgba(14,40,25,0.15) 55%, rgba(14,40,25,0.0) 100%);
}
.hero__lines { position: absolute; inset: 0; z-index: -1; opacity: 0.5; pointer-events: none; }
.hero__inner { padding-block: clamp(7rem, 14vh, 11rem) clamp(3.2rem, 7vh, 5.5rem); width: 100%; }
.hero__eyebrow { color: #B9C8BC; margin-bottom: clamp(1.4rem, 3vw, 2.2rem); }
.hero h1 { max-width: 17ch; }
.hero h1 .mark-stop { color: var(--lime); }
.hero__support { margin-top: clamp(1.6rem, 3vw, 2.4rem); max-width: 54ch; color: #D3DDD3; }
.hero__actions { margin-top: clamp(2rem, 4vw, 2.8rem); display: flex; flex-wrap: wrap; gap: 0.9rem; align-items: center; }
.hero__sig {
  margin-top: clamp(2.4rem, 5vw, 3.4rem); padding-top: 1.4rem;
  border-top: 1px solid rgba(255,255,255,0.14);
  display: flex; align-items: center; gap: 0.8rem; flex-wrap: wrap;
  font-family: var(--serif); font-style: italic; font-weight: 300;
  color: #A9BBAE; font-size: 1.02rem;
}
.hero__scroll {
  position: absolute; right: var(--gutter); bottom: clamp(3.2rem, 7vh, 5.5rem); z-index: 1;
  writing-mode: vertical-rl; font-size: 0.66rem; letter-spacing: 0.24em; text-transform: uppercase;
  color: #9DB0A2; display: flex; align-items: center; gap: 1rem;
}
.hero__scroll .rail { width: 1px; height: 54px; background: linear-gradient(var(--lime), transparent); }
@media (max-width: 640px){ .hero__scroll { display: none; } }

/* =========================================================================
   Generic section pieces
   ========================================================================= */
.section-head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.2rem; margin-bottom: clamp(2.4rem, 5vw, 3.8rem); }
.section-head--split { grid-template-columns: 0.9fr 1.1fr; align-items: end; gap: 2rem 3rem; }
@media (max-width: 820px){ .section-head--split { grid-template-columns: 1fr; } }
.section-head__aside { color: var(--fg-soft); }

.rule { height: 1px; background: var(--rule); border: 0; margin: 0; }

/* Statement band (Point of difference) */
.statement { position: relative; overflow: hidden; }
.statement__lines { position: absolute; inset: 0; opacity: 0.5; pointer-events: none; z-index: 0; }
.statement .container { position: relative; z-index: 1; }
.statement__grid { display: grid; grid-template-columns: 1.25fr 0.75fr; gap: clamp(2rem,5vw,4.5rem); align-items: end; }
@media (max-width: 900px){ .statement__grid { grid-template-columns: 1fr; gap: 2.2rem; } }
.statement h2 .mark-stop { color: var(--lime); }
.chars { display: flex; flex-wrap: wrap; gap: 0.4rem 0.7rem; margin-top: 1.6rem; }
.chars span { font-family: var(--serif); font-style: italic; font-weight: 300; font-size: 1.15rem; color: var(--fg); }
.chars span + span::before { content: ""; }

/* =========================================================================
   STRATEGIC SERVICES — editorial index list
   ========================================================================= */
.svc-list { border-top: 1px solid var(--rule); }
.svc {
  display: grid;
  grid-template-columns: 3.25rem minmax(210px, 1.05fr) minmax(0, 1.45fr) minmax(128px, auto);
  grid-template-areas: "num title desc meta";
  align-items: baseline;
  column-gap: clamp(1.5rem, 2.6vw, 3rem);
  row-gap: 0.35rem;
  padding: clamp(1.4rem, 2.6vw, 2.1rem) 0.4rem;
  border-bottom: 1px solid var(--rule);
  position: relative; transition: padding-left .4s var(--ease), background .4s var(--ease);
}
.svc::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--lime);
  transform: scaleY(0); transform-origin: top; transition: transform .4s var(--ease);
}
.svc:hover { padding-left: 1.4rem; }
.svc:hover::before { transform: scaleY(1); }
.svc__num { grid-area: num; font-family: var(--sans); font-weight: 500; font-size: 0.8rem; letter-spacing: 0.12em; color: var(--fg-faint); }
.svc__title { grid-area: title; font-family: var(--serif); font-weight: 400; font-size: clamp(1.3rem, 1.9vw, 1.8rem); line-height: 1.12; letter-spacing: -0.01em; }
.svc__desc { grid-area: desc; color: var(--fg-soft); font-size: 0.95rem; max-width: 46ch; }
.svc__meta { grid-area: meta; align-self: baseline; color: var(--fg-faint); font-size: 0.82rem; text-align: right; white-space: nowrap; }

/* Tablet — drop the right-hand descriptor, keep title | description split */
@media (max-width: 1040px){
  .svc {
    grid-template-columns: 3rem minmax(190px, 0.95fr) minmax(0, 1.3fr);
    grid-template-areas: "num title desc";
    column-gap: clamp(1.25rem, 2.2vw, 2rem);
  }
  .svc__meta { display: none; }
}
/* Mobile — stack title over description */
@media (max-width: 720px){
  .svc {
    grid-template-columns: 2.4rem 1fr;
    grid-template-areas:
      "num title"
      ".   desc";
    row-gap: 0.5rem;
  }
}

/* "When Glengarra is valuable" aside */
.when { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: clamp(1.6rem,4vw,3.5rem); margin-top: clamp(3rem,6vw,4.5rem); padding-top: clamp(2.4rem,4vw,3rem); border-top: 1px solid var(--rule); }
@media (max-width: 820px){ .when { grid-template-columns: 1fr; } }
.when__list { display: grid; gap: 0.1rem; }
.when__item { display: flex; gap: 1rem; padding: 0.85rem 0; border-bottom: 1px solid var(--rule); align-items: baseline; }
.when__item:last-child { border-bottom: 0; }
.when__item .tick { color: var(--accent); font-size: 0.8rem; transform: translateY(1px); flex: none; }
.when__item p { color: var(--fg); }

/* =========================================================================
   PROGRAMME & PORTFOLIO ADVISORY — layered relationship
   ========================================================================= */
.ppa__grid { display: grid; grid-template-columns: 1fr; gap: clamp(1rem, 2vw, 1.4rem); margin-top: clamp(2.4rem,5vw,3.6rem); }
.ppa-row {
  display: grid; grid-template-columns: 3.2rem 0.9fr 1.4fr; gap: clamp(1rem,3vw,2.6rem);
  padding: clamp(1.6rem,3vw,2.4rem); align-items: start;
  border: 1px solid var(--rule); border-radius: var(--radius);
  background: rgba(255,255,255,0.02); transition: border-color .4s var(--ease), transform .4s var(--ease);
}
.ppa-row:hover { border-color: rgba(198,243,81,0.5); }
.ppa-row__num { font-family: var(--serif); font-size: 1.5rem; color: var(--accent); line-height: 1; }
.ppa-row__t { font-family: var(--serif); font-weight: 400; font-size: clamp(1.3rem,2vw,1.75rem); line-height: 1.12; }
.ppa-row__lead { color: var(--fg-soft); margin-top: 0.6rem; font-size: 0.96rem; }
.ppa-row__tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tag { font-size: 0.78rem; letter-spacing: 0.02em; color: var(--fg-soft); border: 1px solid var(--rule); border-radius: 100px; padding: 0.32em 0.85em; }
@media (max-width: 820px){ .ppa-row { grid-template-columns: 1fr; gap: 0.9rem; } .ppa-row__num { font-size: 1.2rem; } }

.ppa__note { margin-top: 2rem; color: var(--fg-faint); font-size: 0.88rem; display: inline-flex; align-items: center; gap: 0.6em; }

/* =========================================================================
   SELECTED WORK — evidence
   ========================================================================= */
/* Real evidence stories — editorial rows (title + evidence line carry the story) */
.evcases { margin-top: clamp(2rem, 4vw, 3rem); border-top: 1px solid var(--rule); }
.evcase {
  display: grid;
  grid-template-columns: minmax(240px, 0.82fr) minmax(0, 1.18fr);
  column-gap: clamp(1.6rem, 3.4vw, 3.4rem);
  row-gap: 0.4rem;
  padding: clamp(2rem, 3.4vw, 3rem) 0;
  border-bottom: 1px solid var(--rule);
  align-items: start;
  position: relative;
}
.evcase::before {
  content: ""; position: absolute; left: 0; top: -1px; width: 40px; height: 2px; background: var(--lime);
  transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease);
}
.evcase.is-in::before { transform: scaleX(1); }
.evcase__lead { position: relative; }
.evcase__num { font-family: var(--sans); font-weight: 500; font-size: 0.78rem; letter-spacing: 0.16em; color: var(--fg-faint); }
.evcase__meta { margin: 0.85rem 0 1rem; }
.evcase__title { font-family: var(--serif); font-weight: 400; font-size: clamp(1.5rem, 2.2vw, 2rem); line-height: 1.12; letter-spacing: -0.01em; max-width: 18ch; }
.evcase__body { display: flex; flex-direction: column; gap: 1rem; }
.evcase__body p { color: var(--fg-soft); font-size: 0.98rem; }
.evcase__body p .fig { color: var(--fg); font-weight: 600; font-variant-numeric: tabular-nums; }
.evcase__evidence {
  margin-top: 0.5rem; padding-top: 1.15rem; border-top: 1px solid var(--rule);
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.35rem 0.7rem;
}
.evcase__evidence .ev-label { font-size: 0.66rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--fg-faint); font-weight: 500; width: 100%; margin-bottom: 0.55rem; }
.evcase__evidence .ev-seg { font-family: var(--sans); font-weight: 500; font-size: 0.95rem; color: var(--fg); }
.evcase__evidence .ev-arrow { color: var(--lime); font-weight: 600; }
@media (max-width: 820px){
  .evcase { grid-template-columns: 1fr; row-gap: 1.1rem; }
  .evcase__title { max-width: none; }
}
.badge-proto {
  align-self: flex-start; font-size: 0.62rem; letter-spacing: 0.16em; text-transform: uppercase; font-weight: 600;
  color: var(--lime); border: 1px solid rgba(198,243,81,0.5); border-radius: 100px; padding: 0.3em 0.7em;
}
.work__foot { margin-top: clamp(2rem,4vw,3rem); display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }

/* =========================================================================
   STRATEGY GROUNDED IN DELIVERY
   ========================================================================= */
.delivery__grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: clamp(1.6rem,4vw,3rem); align-items: stretch; margin-top: clamp(2.4rem,5vw,3.4rem); }
@media (max-width: 860px){ .delivery__grid { grid-template-columns: 1fr; } }
.delivery-card { border: 1px solid var(--rule); border-radius: var(--radius); padding: clamp(1.6rem,3vw,2.4rem); display: flex; flex-direction: column; }
.delivery-card--primary { background: var(--bone-2); }
.delivery-card--sub { background: transparent; }
.delivery-card__k { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.1rem; }
.delivery-card__t { font-family: var(--serif); font-size: clamp(1.5rem,2.4vw,2.05rem); font-weight: 400; }
.delivery-card--sub .delivery-card__t { font-size: clamp(1.3rem,2vw,1.6rem); }
.delivery-card p { color: var(--fg-soft); }
.chip-row { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-top: 1.3rem; }
.chip { font-size: 0.8rem; color: var(--fg); border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.4em 0.75em; background: var(--bg); }
.delivery-card--primary .chip { background: var(--bone); }
.subtle-tag { font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-faint); font-weight: 500; }

/* =========================================================================
   THE GLENGARRA METHOD — Precision Instrument
   ========================================================================= */
.method__top { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem 3rem; align-items: end; }
@media (max-width: 820px){ .method__top { grid-template-columns: 1fr; } }
.method__flow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-top: clamp(2.6rem,5vw,3.8rem); border-top: 1px solid var(--rule); }
@media (max-width: 720px){ .method__flow { grid-template-columns: 1fr 1fr; } }
.mstep { padding: clamp(1.4rem,2.6vw,2rem) clamp(1rem,2vw,1.6rem) clamp(1.4rem,2.6vw,2rem) 0; border-right: 1px solid var(--rule); position: relative; }
.mstep:last-child { border-right: 0; }
@media (max-width: 720px){ .mstep:nth-child(2n){ border-right: 0; } .mstep { border-bottom: 1px solid var(--rule); } }
.mstep__i { display: flex; align-items: center; gap: 0.7rem; margin-bottom: 1rem; }
.mstep__dot { width: 10px; height: 10px; border-radius: 50%; border: 1.5px solid var(--accent); position: relative; }
.mstep__dot::after { content: ""; position: absolute; inset: 2px; border-radius: 50%; background: var(--accent); transform: scale(0); transition: transform .5s var(--ease); }
.mstep.is-in .mstep__dot::after { transform: scale(1); }
.mstep__n { font-size: 0.72rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--fg-faint); font-weight: 500; }
.mstep__t { font-family: var(--serif); font-size: clamp(1.5rem,2.4vw,2rem); font-weight: 400; margin-bottom: 0.5rem; }
.mstep__d { color: var(--fg-soft); font-size: 0.92rem; max-width: 26ch; }

/* Dimensions instrument */
.dims { margin-top: clamp(2.6rem,5vw,3.6rem); border: 1px solid var(--rule); border-radius: var(--radius); padding: clamp(1.6rem,3vw,2.6rem); background: rgba(255,255,255,0.02); }
.dims__head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.4rem; }
.dims__title { font-family: var(--serif); font-size: 1.2rem; }
.dims__viz { width: 100%; }
.dims__legend { display: flex; flex-wrap: wrap; gap: 0.6rem 1.4rem; margin-top: 1.2rem; }
.dims__legend span { font-size: 0.82rem; letter-spacing: 0.02em; color: var(--fg-soft); display: inline-flex; align-items: center; gap: 0.5em; }
.dims__legend i { width: 8px; height: 8px; border-radius: 50%; background: var(--lime); display: inline-block; }

/* =========================================================================
   MARKETS
   ========================================================================= */
.markets__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.6rem,4vw,3rem); margin-top: clamp(2.4rem,5vw,3.4rem); }
@media (max-width: 860px){ .markets__grid { grid-template-columns: 1fr; } }
.mk-panel { border: 1px solid var(--rule); border-radius: var(--radius); padding: clamp(1.6rem,3vw,2.4rem); }
.mk-panel--proven { background: var(--forest); color: var(--bone); border-color: transparent; }
.mk-panel--proven .subtle-tag, .mk-panel--proven .mk-panel__lead { color: #C6D3C6; }
.mk-panel__k { display: flex; align-items: center; gap: 0.7em; margin-bottom: 1.1rem; }
.mk-panel__t { font-family: var(--serif); font-size: clamp(1.5rem,2.2vw,1.9rem); font-weight: 400; margin: 0.4rem 0 0.7rem; }
.mk-panel__lead { color: var(--fg-soft); font-size: 0.96rem; }
.mk-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.4rem; }
.mk-tag { font-size: 0.82rem; padding: 0.4em 0.85em; border-radius: 100px; border: 1px solid var(--rule); }
.mk-panel--proven .mk-tag { border-color: rgba(255,255,255,0.22); }
.mk-tag--live { border-color: var(--lime); color: var(--lime); }
.mk-panel__note { margin-top: 1.3rem; font-size: 0.8rem; color: var(--fg-faint); }

/* =========================================================================
   CLIENT PERSPECTIVE
   ========================================================================= */
/* Testimonials — the quotations carry the section; roles/sectors give authority */
.testimonials { margin-top: clamp(2.4rem, 5vw, 3.6rem); border-top: 1px solid var(--rule); }
.testi {
  display: grid;
  grid-template-columns: minmax(190px, 0.32fr) minmax(0, 0.68fr);
  column-gap: clamp(1.6rem, 3.4vw, 3.4rem);
  row-gap: 0.9rem;
  padding: clamp(2.2rem, 3.8vw, 3.4rem) 0;
  border-bottom: 1px solid var(--rule);
  align-items: start;
}
.testi__quote {
  grid-column: 2; grid-row: 1; margin: 0;
  font-family: var(--serif); font-weight: 300;
  font-size: clamp(1.3rem, 1.5vw + 0.85rem, 1.85rem);
  line-height: 1.36; letter-spacing: -0.01em;
  color: var(--fg); max-width: 42ch; text-wrap: pretty;
}
.testi__who { grid-column: 1; grid-row: 1; display: flex; flex-direction: column; gap: 0.35rem; padding-top: 0.5rem; }
.testi__who::before { content: ""; width: 30px; height: 2px; background: var(--lime); margin-bottom: 1rem; }
.testi__role { font-family: var(--sans); font-weight: 600; font-size: 0.98rem; color: var(--fg); }
.testi__sector { font-family: var(--sans); font-size: 0.76rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-faint); }
@media (max-width: 820px){
  .testi { grid-template-columns: 1fr; row-gap: 1.2rem; }
  .testi__quote { grid-column: 1; grid-row: 1; max-width: none; }
  .testi__who { grid-column: 1; grid-row: 2; padding-top: 0; }
  .testi__who::before { margin-bottom: 0.8rem; }
}

/* Closing brand signature — the Glengarra identifier as the end of the argument */
.signature__inner { max-width: 60ch; }
.signature__tick { display: block; width: 48px; height: 2px; background: var(--lime); margin-bottom: clamp(1.6rem, 3vw, 2.4rem); }
.signature__line1 { font-family: var(--serif); font-weight: 300; font-size: clamp(1.6rem, 3vw, 2.6rem); line-height: 1.05; letter-spacing: -0.015em; color: var(--fg-soft); }
.signature__line2 { font-family: var(--serif); font-weight: 300; font-size: clamp(2.6rem, 6.2vw, 5rem); line-height: 1.0; letter-spacing: -0.02em; color: var(--fg); margin-top: 0.12em; }
.signature__line2 .mark-stop { color: var(--lime); }
.signature__belief { margin-top: clamp(1.8rem, 3.2vw, 2.6rem); max-width: 52ch; color: var(--fg-soft); font-weight: 300; font-size: clamp(1.05rem, 0.7vw + 0.9rem, 1.3rem); line-height: 1.5; }

/* =========================================================================
   INSIGHTS
   ========================================================================= */
.insights__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.4rem,3vw,2.2rem); margin-top: clamp(2.4rem,5vw,3.4rem); }
@media (max-width: 860px){ .insights__grid { grid-template-columns: 1fr; } }
.insight { display: flex; flex-direction: column; gap: 1rem; padding-top: 1.4rem; border-top: 1px solid var(--rule); transition: border-color .3s var(--ease); }
.insight:hover { border-top-color: var(--lime); }
.insight__meta { display: flex; align-items: center; gap: 0.8rem; font-size: 0.74rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--fg-faint); font-weight: 500; }
.insight__t { font-family: var(--serif); font-size: clamp(1.3rem,1.9vw,1.6rem); font-weight: 400; line-height: 1.18; }
.insight__d { color: var(--fg-soft); font-size: 0.92rem; }
.insight .link { margin-top: auto; align-self: flex-start; }

/* =========================================================================
   FINAL CTA
   ========================================================================= */
.cta { position: relative; overflow: hidden; isolation: isolate; }
.cta__media { position: absolute; inset: 0; z-index: -2; }
.cta__media img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.05) brightness(0.5); mix-blend-mode: luminosity; opacity: 0.55; }
.cta__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(11,32,20,0.85), rgba(11,32,20,0.94)); }
.cta__lines { position: absolute; inset: 0; z-index: -1; opacity: 0.45; }
.cta__inner { text-align: left; max-width: 68ch; }
.cta h2 { max-width: 19ch; }
.cta h2 .mark-stop { color: var(--lime); }
.cta__lead { margin-top: 1.6rem; max-width: 52ch; color: #D3DDD3; }
@media (max-width: 720px){ .cta h2 { max-width: 16ch; } }
.cta__actions { margin-top: 2.2rem; display: flex; gap: 0.9rem; flex-wrap: wrap; }

/* =========================================================================
   FOOTER
   ========================================================================= */
.footer { background: var(--forest-deep); color: var(--bone); padding-top: clamp(3.4rem,6vw,5rem); }
.footer__top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 2rem; padding-bottom: clamp(2.6rem,5vw,3.6rem); border-bottom: 1px solid rgba(255,255,255,0.14); }
@media (max-width: 860px){ .footer__top { grid-template-columns: 1fr 1fr; gap: 2.4rem 1.5rem; } }
@media (max-width: 520px){ .footer__top { grid-template-columns: 1fr; } }
.footer__brand img { height: 30px; margin-bottom: 1.2rem; }
.footer__brand p { color: #A9BBAE; font-size: 0.9rem; max-width: 34ch; }
.footer__col h4 { font-size: 0.72rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--lime); font-weight: 500; margin-bottom: 1.1rem; }
.footer__col ul { display: flex; flex-direction: column; gap: 0.65rem; }
.footer__col a, .footer__col p { color: #C6D3C6; font-size: 0.92rem; transition: color .25s var(--ease); }
.footer__col a:hover { color: var(--bone); }
.footer__bottom { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding-block: 1.8rem 2.4rem; }
.footer__sig { font-family: var(--serif); font-style: italic; font-weight: 300; color: #A9BBAE; }
.footer__sig .mark { font-style: normal; }
.footer__legal { display: flex; gap: 1.4rem; flex-wrap: wrap; color: #8FA592; font-size: 0.8rem; }
.footer__legal a:hover { color: var(--bone); }

/* =========================================================================
   Reveal animation
   ========================================================================= */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: .08s; }
.reveal[data-delay="2"] { transition-delay: .16s; }
.reveal[data-delay="3"] { transition-delay: .24s; }
.reveal[data-delay="4"] { transition-delay: .32s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .hero__media img { transform: none !important; }
}

/* Instrument stroke draw */
.draw { stroke-dasharray: var(--len, 1000); stroke-dashoffset: var(--len, 1000); transition: stroke-dashoffset 1.4s var(--ease); }
.dims.is-in .draw { stroke-dashoffset: 0; }
.dims .node { opacity: 0; transform: scale(0.6); transform-origin: center; transition: opacity .5s var(--ease), transform .5s var(--ease); }
.dims.is-in .node { opacity: 1; transform: scale(1); }
.dims.is-in .node.n2 { transition-delay: .15s; }
.dims.is-in .node.n3 { transition-delay: .3s; }
.dims.is-in .node.n4 { transition-delay: .45s; }
.dims.is-in .node.n5 { transition-delay: .6s; }

/* focus visibility */
:focus-visible { outline: 2px solid var(--lime); outline-offset: 3px; border-radius: 2px; }

/* Dev capture mode (only when <html class="shot">) */
.shot .hero { min-height: 760px; }
.shot .reveal { opacity: 1 !important; transform: none !important; }
.shot .site-header { position: absolute; }
.shot-scroll .site-header { display: none; }

/* utility */
.stack-sm > * + * { margin-top: 1rem; }
.stack-md > * + * { margin-top: 1.6rem; }

/* =========================================================================
   LARGE-DESKTOP ART DIRECTION (shared) — ≥1500px only
   A genuinely separate layer, not a change to the base curves above: every
   rule here is written as clamp(ORIGINAL, calc(ORIGINAL + slope * (100vw -
   1500px)), NEW-CEILING). Below 1500px the calc() term is smaller than
   ORIGINAL, so clamp's floor wins and the value is byte-identical to the
   protected base rule above — nothing here can alter 1280/1366/1440/tablet/
   mobile rendering. From 1500px the value grows continuously (no snap) to
   the new ceiling by ~1950px, then holds. Page-specific large-desktop
   composition rules (grid gaps, diagram/image scale) live in each page's
   own CSS file under the same ≥1500px threshold; this block only covers
   the shared type scale. The canvas itself (--container) now grows
   continuously from its own base definition above — it no longer needs
   a media-query gate here.
   ========================================================================= */
@media (min-width: 1500px) {
  .display { font-size: clamp(5.4rem, calc(5.4rem + 0.057 * (100vw - 1500px)), 7rem); }
  .h-xl    { font-size: clamp(3.9rem, calc(3.9rem + 0.039 * (100vw - 1500px)), 5rem); }
  .h-lg    { font-size: clamp(2.9rem, calc(2.9rem + 0.032 * (100vw - 1500px)), 3.8rem); }
  /* .h-md's own base curve (1.6vw) doesn't actually reach its 1.7rem
     ceiling until ~1700px, so the floor here must match its TRUE value at
     1500px (1.5rem) — using the ceiling itself as the floor would jump
     the value upward right at this breakpoint. */
  .h-md    { font-size: clamp(1.5rem, calc(1.5rem + 0.0213 * (100vw - 1500px)), 2.1rem); }
  .lead    { font-size: clamp(1.5rem, calc(1.5rem + 0.0124 * (100vw - 1500px)), 1.85rem); }
  body     { font-size: clamp(1.125rem, calc(1.125rem + 0.0062 * (100vw - 1500px)), 1.3rem); }
  /* Reading-measure ch-caps (.measure/.measure-sm/.measure-xs) are left
     untouched here deliberately — the character-count-per-line a paragraph
     wraps at should not change just because the screen is bigger; growing
     the type above (with measure fixed in ch) already makes the physical
     column wider in proportion, which is the correct large-desktop
     behaviour for prose. Eyebrows/labels are likewise left at their
     original size — that register is meant to stay small and precise. */
  .chars span { font-size: clamp(1.15rem, calc(1.15rem + 0.01 * (100vw - 1500px)), 1.4rem); }
}
.nowrap { white-space: nowrap; }
