/* ==========================================================================
   HERITAGE — the hero, rebuilt from the founder's artifact (2026-09-30).
   Loaded after x-heritage.css on a/heritage.html only. Scope: .ht-hh.

   A study at dusk bled across the hero, and the lockup set on the navy wall
   to its right on one central axis: crest, name, the two specimen dates,
   the argument, the definition, one ruled action, and the facts in three
   compartments. Still, as the page is: no animation, no transition.

   Positions are in --u, 1/1689 of the hero (the photograph's own width);
   the column is in normal flow so the hero grows if the text needs it.
   Faces and palette are the page's (Prata HT, Petrona HT, --ht-*).
   ========================================================================== */

.ht-hero.ht-hh {
  --u: calc(100cqi / 1689);
  container-type: inline-size;
  position: relative;
  display: grid;
  aspect-ratio: 1689 / 931;             /* a minimum: the column may grow it */
  padding: 0;
  background: var(--ht-navy2);
  /* Full width of the page column, rising behind the empty top bar. */
  margin: calc(-3rem - var(--s2, 0.5rem)) calc(-1 * var(--s6, 2rem)) 0;
}
@media (max-width: 60rem) {
  .ht-hero.ht-hh { margin-inline: calc(-1 * var(--s4, 1rem)); }
}
/* container-type on the hero means its own cqi can't be read from itself;
   --u resolves on the children, where 100cqi is the hero's width. */

.ht-hh__fig { position: absolute; inset: 0; margin: 0; }
.ht-hh__photo { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 30% 50%; }
/* Settle the light on the wall under the type; the left of the room is untouched. */
.ht-hh__fig::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(14, 24, 48, 0) 48%, rgba(14, 24, 48, 0.42) 64%, rgba(14, 24, 48, 0.5) 100%);
}
.ht-hh__cap {
  position: absolute; z-index: 1; left: calc(56 * var(--u)); bottom: calc(26 * var(--u));
  max-width: min(46ch, calc(560 * var(--u)));
  font: italic 300 13px/1.45 var(--ht-serif); color: var(--ht-stone); text-align: left;
}
.ht-hh__cap b { font-style: normal; font-weight: 600; color: var(--ht-cream); }

/* ---- the mock nav: the house's own site bar, along the top-left of the
        photograph (the curtain's shadow), clear of the action cluster. ---- */
.ht-hh__nav {
  position: absolute; z-index: 2; top: calc(40 * var(--u)); left: calc(56 * var(--u));
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px max(calc(28 * var(--u)), 16px);
  font: 400 max(calc(13 * var(--u)), 11px)/1 var(--ht-display); letter-spacing: 0.2em; text-transform: uppercase;
}
.ht-hh__nav a { display: inline-flex; align-items: center; min-height: 32px; color: var(--ht-cream); text-decoration: none; }
.ht-hh__nav a:hover { color: var(--ht-gold); }
.ht-hh__nav a:focus-visible { outline: 1px solid var(--ht-gold); outline-offset: 4px; }
.ht-hh__logo { margin-right: max(calc(10 * var(--u)), 4px); }
.ht-hh__logo img { display: block; height: max(calc(15 * var(--u)), 11px); width: auto; }

/* ---- the column: one axis, centred on the wall ------------------------ */
.ht-hh__col {
  position: relative; z-index: 1;
  align-self: start;
  /* The floor never exceeds what the wall leaves (audit 2026-10-01: at
     1184–1216 a flat 420px pushed the column 14px past the hero). */
  width: calc(600 * var(--u)); min-width: min(420px, calc(100cqi - 969 * var(--u) - 16px));
  /* 2.5rem more than the artifact at the top: the hero now rises behind the top bar. */
  margin: calc(140 * var(--u) + 2.5rem) 0 calc(80 * var(--u)) calc(969 * var(--u));
  display: flex; flex-direction: column; align-items: center; text-align: center;
}
.ht-hh .ht-hh__crest { width: max(calc(138 * var(--u)), 96px); margin: 0; }
.ht-hh .ht-hh__h1 {
  margin: calc(22 * var(--u)) -0.12em 0 0;  /* the tracking after the last letter would push it off the axis */
  font-size: max(calc(84 * var(--u)), 44px); line-height: 1.05; letter-spacing: 0.12em;
}
.ht-hh .ht-hh__est { margin-top: calc(18 * var(--u)); font-size: max(calc(15 * var(--u)), 13px); }
.ht-hh .ht-hh__est i { flex-basis: calc(48 * var(--u)); }
.ht-hh .ht-hh__estcap { margin: 8px auto 0; max-width: 36ch; font-size: 14px; }
.ht-hh__tag {
  margin: calc(30 * var(--u)) 0 0;
  font: italic 300 max(calc(33 * var(--u)), 22px)/1.25 var(--ht-serif); color: var(--ht-cream);
}
.ht-hh__lede {
  margin: calc(22 * var(--u)) auto 0; max-width: 32em;
  font: 300 max(calc(20 * var(--u)), 17px)/1.6 var(--ht-serif); color: var(--ht-stone);
}
.ht-hh__cta { margin: calc(30 * var(--u)) 0 0; }
.ht-hh__cta a {
  display: inline-flex; align-items: center; gap: 14px;
  min-height: 52px; padding: 0 44px;
  border: 1px solid var(--ht-gold);
  font: 400 max(calc(18 * var(--u)), 16px)/1 var(--ht-serif); letter-spacing: 0.02em;
  color: var(--ht-cream); text-decoration: none;
}
.ht-hh__cta a:hover { background: rgba(176, 141, 62, 0.12); }
.ht-hh__cta a:focus-visible { outline: 1px solid var(--ht-gold); outline-offset: 5px; }
.ht-hh__cta svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.4; }

.ht-hh__facts {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  width: 100%; margin: calc(64 * var(--u)) 0 0;
}
.ht-hh__facts div { padding: 4px 18px; border-left: 1px solid rgba(201, 194, 176, 0.35); }
.ht-hh__facts div:first-child { border-left: 0; }
.ht-hh__facts dt { font: 400 11px/1.5 var(--ht-display); letter-spacing: 0.3em; text-transform: uppercase; color: #C9A75A; }   /* a lighter gold at 11px: --ht-gold measured 2.3:1 at p10 (audit 2026-10-01) */
.ht-hh__facts dd { margin: 8px 0 0; font: 300 16px/1.45 var(--ht-serif); color: var(--ht-cream); }

/* ---- narrower windows -------------------------------------------------- */
/* Rail fixed but the room narrow: keep the photograph, move the axis in. */
@media (max-width: 1180px) {
  .ht-hh__col { width: auto; min-width: 0; margin: 96px 32px 56px 50%; }
  .ht-hh__photo { object-position: 18% 50%; }
}

/* One column: the room above, the lockup beneath on the navy. */
@media (max-width: 52rem) {
  .ht-hero.ht-hh { display: block; aspect-ratio: auto; }
  .ht-hh__fig { position: relative; inset: auto; }
  .ht-hh__fig::after { background: linear-gradient(180deg, rgba(14, 24, 48, 0.55) 0%, rgba(14, 24, 48, 0) 22%, rgba(14, 24, 48, 0) 60%, var(--ht-navy2) 100%); }
  .ht-hh__photo { height: auto; aspect-ratio: 4 / 3; object-position: 12% 50%; }
  .ht-hh__cap { position: relative; left: auto; bottom: auto; max-width: none; padding: 12px 16px 0; }
  .ht-hh__nav { top: 16px; left: 16px; right: 16px; gap: 4px 16px; font-size: 11px; letter-spacing: 0.18em; }
  .ht-hh__logo { flex-basis: 100%; }
  .ht-hh__col { margin: 40px 16px 56px; }
  .ht-hh__facts { grid-template-columns: 1fr; gap: 18px; }
  .ht-hh__facts div { border-left: 0; padding: 14px 0 0; border-top: 1px solid rgba(201, 194, 176, 0.35); }
  .ht-hh__facts div:first-child { border-top: 0; padding-top: 0; }
}

/* Narrow desktop: the nav stays one row along the top; the action bar sits under it
   (founder, 2026-10-01), so it no longer drops or keeps to the photograph's half. */
