/* Home About (18 Nov 2026 redesign): heading, lead, one real texture photo and the fabric rail.
   The rail is twelve lengths of fabric hanging from a rod; each one is a .fan-sw button that opens the sample viewer
   (built by assets/js/swatch-fan.js). Phone first: heading, lead and photo in the first screen, rail in two rows of six. */
.ha { display: grid; gap: 0; }
.ha > h2 { max-width: 15ch; text-wrap: balance; font-size: clamp(38px, 10.4vw, 46px); line-height: 1.02; }
.ha > h2 em { font-style: italic; letter-spacing: -.02em; }
.ha-lead { margin: 18px 0 0; max-width: 40ch; color: var(--walnut); }
.ha-ph { margin: 28px 0 0; border-radius: var(--r); overflow: hidden; aspect-ratio: 5 / 4; background: var(--linen); }
.ha-ph img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%; transform: scale(1.001); }
.js .ha-ph.rv img { transform: scale(1.07); transition: transform 2.2s var(--ease); }
.js .ha-ph.rv.in img { transform: scale(1.001); }
.ha-more { margin-top: 26px; }
.ha-more p { max-width: 44ch; color: var(--walnut-soft); margin: 0; }
.ha-more .ha-act { margin-top: 20px; }
.ha-act .btn { width: 100%; }
@media (min-width: 600px) { .ha-act .btn { width: auto; } }

/* fabric rail */
.ha-rail { margin-top: 44px; --h: 128px; --gap: 6px; --rowgap: 22px; }
.ha-rail .fan-cards { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); column-gap: var(--gap); row-gap: var(--rowgap); grid-auto-rows: calc(var(--h) + 14px); align-items: start; padding-top: 2px; }
/* the rods: one per row, drawn left to right as the rail comes into view */
.ha-rail .fan-cards::before, .ha-rail .fan-cards::after { content: ''; position: absolute; left: -5px; right: -5px; top: 0; height: 2px; border-radius: 2px; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); transition: transform 1.1s var(--ease); z-index: 2; pointer-events: none; }
.ha-rail .fan-cards::after { top: calc(var(--h) + 14px + var(--rowgap)); transition-delay: .25s; }
.ha-rail .fan-cards.in::before, .ha-rail .fan-cards.in::after { transform: none; }
.ha-rail .fan-sw { position: relative; display: block; width: 100%; height: 0; padding: 0; border: 0; background: var(--linen); cursor: pointer; overflow: hidden; -webkit-tap-highlight-color: transparent;
  clip-path: var(--pink); transition: height 1s var(--ease) calc(var(--i) * 55ms + .15s), opacity .45s var(--ease); }
.ha-rail .fan-cards.in .fan-sw { height: calc(var(--h) * var(--len)); }
.ha-rail .fan-cards.ready .fan-sw { transition: height .55s var(--ease), opacity .45s var(--ease); }
.ha-rail .fan-cards.in .fan-sw.on { height: calc(var(--h) * var(--len) + 14px); }
.ha-rail .fan-cards.has-on .fan-sw:not(.on) { opacity: .62; }
.ha-rail .fan-sw canvas { position: absolute; left: 50%; top: 0; width: 104px; height: 300px; max-width: none; margin-left: -52px; }
/* the fall of the cloth: a soft fold down each length */
.ha-rail .fan-sw::before { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(90deg, rgba(42,35,32,.16) 0%, rgba(42,35,32,0) 26%, rgba(255,255,255,.10) 52%, rgba(42,35,32,0) 74%, rgba(42,35,32,.14) 100%), linear-gradient(180deg, rgba(42,35,32,.18) 0, rgba(42,35,32,0) 14px); }
.ha-rail .fan-sw:focus-visible { outline: none; }
.ha-rail .fan-sw:focus-visible::after { content: ''; position: absolute; inset: 0 0 5px; z-index: 2; box-shadow: inset 0 0 0 2px var(--walnut), inset 0 0 0 4px var(--limewash); pointer-events: none; }
.ha-cap { display: flex; align-items: center; justify-content: space-between; gap: 8px 20px; flex-wrap: wrap; margin-top: 10px; min-height: 44px; }
.ha-now { margin: 0; display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 10px; max-width: none; transition: opacity .16s linear; }
.ha-now.swap { opacity: 0; }
.ha-now b { font: 400 22px/1.2 var(--display); letter-spacing: -.01em; color: var(--walnut); }
.ha-now span { font: 400 14.5px/1.4 var(--sans); color: var(--walnut-soft); }
.ha-all { display: inline-flex; align-items: center; min-height: 44px; padding: 0; border: 0; background: none; font: 500 15px/1.2 var(--sans); color: var(--accent); cursor: pointer; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; transition: color .25s var(--ease); }
.ha-all:hover { color: var(--walnut); }

@media (min-width: 700px) and (max-width: 899px) {
  .ha-rail { --h: 210px; }
  .ha-rail .fan-cards { grid-template-columns: repeat(12, 1fr); }
  .ha-rail .fan-cards::after { display: none; }
  .ha-ph { aspect-ratio: 16 / 9; }
}
@media (min-width: 900px) {
  .ha { grid-template-columns: repeat(12, 1fr); column-gap: clamp(24px, 3vw, 48px); grid-template-rows: auto auto auto 1fr; }
  .ha > h2 { grid-column: 1 / 11; max-width: 17ch; font-size: clamp(44px, 5.4vw, 84px); line-height: 1; }
  .ha-ph { grid-column: 1 / 6; grid-row: 2 / 5; margin-top: clamp(36px, 4vw, 56px); aspect-ratio: auto; min-height: 480px; }
  .ha-ph img { object-position: 42% 50%; }
  .ha-lead { grid-column: 7 / 13; grid-row: 2; margin-top: clamp(36px, 4vw, 56px); font-size: clamp(19px, 1.55vw, 22px); line-height: 1.45; max-width: 38ch; text-wrap: pretty; }
  .ha-more { grid-column: 7 / 13; grid-row: 3; margin-top: 22px; }
  .ha-more .ha-act { margin-top: 26px; }
  .ha-rail { grid-column: 7 / 13; grid-row: 4; align-self: end; margin-top: 44px; --h: 132px; --gap: 8px; }
}
@media (min-width: 1280px) {
  .ha-rail { --h: 196px; --gap: 4px; }
  .ha-rail .fan-cards { grid-template-columns: repeat(12, 1fr); }
  .ha-rail .fan-cards::after { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .ha-rail .fan-sw, .ha-rail .fan-cards.ready .fan-sw, .ha-rail .fan-cards::before, .ha-rail .fan-cards::after, .ha-now, .js .ha-ph.rv img { transition: none; }
  .js .ha-ph.rv img { transform: scale(1.001); }
}
