/* ================================================================
   KEYSTONE HORIZON — home.css
   Cinematic homepage layer. Loads AFTER styles.css and only on
   index.html. Other pages depend on styles.css — nothing here
   should be required by them.
   ================================================================ */

/* ----------------------------------------------------------------
   0. Safety nets & global cinema layers
   ---------------------------------------------------------------- */

/* If JS never runs, nothing may stay hidden. */
html:not(.js) .reveal,
html:not(.js) .fx-wipe,
html:not(.js) .fx-scale {
  opacity: 1 !important;
  transform: none !important;
  clip-path: none !important;
}

/* Film grain — fixed, above everything, non-interactive */
.grain {
  position: fixed;
  inset: 0;
  z-index: 210;
  pointer-events: none;
  overflow: hidden;
}

.grain::before {
  content: "";
  position: absolute;
  top: -100%;
  left: -100%;
  width: 300%;
  height: 300%;
  opacity: 0.045;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='saturate' values='0'/></filter><rect width='240' height='240' filter='url(%23n)' opacity='0.7'/></svg>");
  background-size: 240px 240px;
  animation: grain-shift 1.6s steps(6) infinite;
}

@keyframes grain-shift {
  0%   { transform: translate3d(0, 0, 0); }
  20%  { transform: translate3d(-4%, 3%, 0); }
  40%  { transform: translate3d(3%, -5%, 0); }
  60%  { transform: translate3d(-5%, -2%, 0); }
  80%  { transform: translate3d(4%, 4%, 0); }
  100% { transform: translate3d(0, 0, 0); }
}

/* Reading-progress hairline */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 220;
  background: linear-gradient(90deg, var(--accent-deep), var(--accent));
  transform: scaleX(0);
  transform-origin: left;
  pointer-events: none;
}

/* Cursor-following glow — desktop, fine pointers only */
.cursor-glow {
  position: fixed;
  top: 0;
  left: 0;
  width: 520px;
  height: 520px;
  z-index: 2;
  pointer-events: none;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 162, 107, 0.06) 0%, rgba(201, 162, 107, 0.025) 38%, transparent 65%);
  will-change: transform;
}

.cursor-glow[hidden] { display: none; }

/* Skip link */
.skip-link {
  position: fixed;
  top: -60px;
  left: 16px;
  z-index: 400;
  background: var(--accent);
  color: #0b0d10;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 12px 18px;
  transition: top 0.2s ease;
}

.skip-link:focus { top: 12px; }

/* Reveal variants (IntersectionObserver adds .in) */
.fx-wipe {
  clip-path: inset(0 0 100% 0);
  transition: clip-path 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}

.fx-wipe.in { clip-path: inset(0 0 0% 0); }

.fx-scale {
  opacity: 0;
  transform: scale(0.96);
  transition: opacity 0.9s cubic-bezier(0.22, 1, 0.36, 1), transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

.fx-scale.in { opacity: 1; transform: scale(1); }

/* Magnetic buttons get a soft spring */
[data-magnetic] {
  will-change: transform;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ----------------------------------------------------------------
   1. HERO — layered parallax, line-draw skyline, kinetic type
   ---------------------------------------------------------------- */

.hero-cine { isolation: isolate; }

/* Slow-shifting aurora gradient behind everything */
.hero-aurora {
  position: absolute;
  inset: -18%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(38% 44% at 74% 22%, rgba(201, 162, 107, 0.15), transparent 70%),
    radial-gradient(46% 54% at 16% 80%, rgba(96, 128, 186, 0.11), transparent 70%),
    radial-gradient(28% 30% at 44% 8%, rgba(201, 162, 107, 0.06), transparent 70%);
  animation: aurora-drift 26s ease-in-out infinite alternate;
  will-change: transform;
}

@keyframes aurora-drift {
  0%   { transform: translate3d(-2.5%, -1.5%, 0) scale(1); opacity: 0.75; }
  100% { transform: translate3d(3%, 2.5%, 0) scale(1.09); opacity: 1; }
}

/* Parallax wrappers (JS drives transform on [data-para]) */
.hero-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  will-change: transform;
}

/* Keystone wedge — draws itself, then floats */
.hero-cine .hero-keystone {
  position: absolute;
  top: 6%;
  right: -5%;
  width: clamp(300px, 38vw, 580px);
  height: auto;
  color: rgba(201, 162, 107, 0.13);
  animation: keystone-float 14s ease-in-out infinite alternate;
}

@keyframes keystone-float {
  from { translate: 0 0; rotate: 0deg; }
  to   { translate: 0 -22px; rotate: 1.2deg; }
}

html.js .hero-keystone path,
html.js .hero-keystone line,
html.js .hero-keystone circle {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: line-draw 2s cubic-bezier(0.6, 0, 0.2, 1) forwards;
  animation-delay: var(--d, 0.2s);
}

/* Skyline — animated line drawing on load */
.hero-cine .hero-skyline {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 44%;
  color: rgba(140, 165, 205, 0.20);
}

html.js .hero-skyline path {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: line-draw 2.6s cubic-bezier(0.65, 0, 0.25, 1) forwards;
  animation-delay: var(--d, 0s);
}

html.js .hero-skyline line {
  opacity: 0;
  animation: window-on 0.7s ease forwards;
  animation-delay: var(--d, 2.4s);
}

@keyframes line-draw {
  to { stroke-dashoffset: 0; }
}

@keyframes window-on {
  to { opacity: 0.6; }
}

/* Kinetic headline — masked line rises */
.hero-title-cine {
  font-size: clamp(58px, 11.5vw, 164px);
  line-height: 0.94;
  position: relative;
}

.hero-title-cine .mask {
  display: block;
  overflow: hidden;
  padding-bottom: 0.06em; /* keep descenders inside the mask */
  margin-bottom: -0.06em;
}

.hero-title-cine .word { display: block; }

html.js .hero-title-cine .word {
  transform: translateY(112%);
  animation: word-rise 1s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

html.js .hero-title-cine .mask:nth-child(1) .word { animation-delay: 0.15s; }
html.js .hero-title-cine .mask:nth-child(2) .word { animation-delay: 0.30s; }
html.js .hero-title-cine .mask:nth-child(3) .word { animation-delay: 0.45s; }

@keyframes word-rise {
  to { transform: translateY(0); }
}

.hero-title-cine .word.outline {
  color: transparent;
  -webkit-text-stroke: 2px rgba(233, 229, 221, 0.85);
  margin-left: clamp(24px, 8vw, 140px);
}

/* Fade-up used inside hero (independent of scroll observer) */
html.js .hero-fade {
  opacity: 0;
  transform: translateY(26px);
  animation: hero-fade 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

html.js .hero-fade.hd1 { animation-delay: 0.65s; }
html.js .hero-fade.hd2 { animation-delay: 0.8s; }
html.js .hero-fade.hd3 { animation-delay: 0.95s; }

@keyframes hero-fade {
  to { opacity: 1; transform: none; }
}

.hero-inner { will-change: transform, opacity; }

/* ----------------------------------------------------------------
   2. MARQUEE TICKERS
   ---------------------------------------------------------------- */

.mq {
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: var(--bg-panel);
  padding: 24px 0;
}

.mq-track {
  display: flex;
  width: max-content;
  animation: mq-scroll 42s linear infinite;
}

.mq-track > span {
  font-family: var(--font-display);
  font-size: clamp(26px, 3.4vw, 44px);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(190, 205, 228, 0.24);
  padding-right: 0.6em;
}

.mq-track b {
  font-weight: 400;
  color: var(--accent);
  -webkit-text-stroke: 0;
}

@keyframes mq-scroll {
  to { transform: translateX(-50%); }
}

/* Giant outline marquee before the contact chapter */
.mq-giant {
  border-top: 1px solid var(--line);
  border-bottom: none;
  background: var(--bg);
  padding: clamp(36px, 6vw, 72px) 0;
}

.mq-giant .mq-track { animation-duration: 64s; }

.mq-giant .mq-track > span {
  font-size: clamp(70px, 12vw, 168px);
  -webkit-text-stroke: 1.5px rgba(190, 205, 228, 0.18);
}

.mq-giant .mq-track b { -webkit-text-stroke: 1.5px var(--accent-deep); color: transparent; }

/* ----------------------------------------------------------------
   3. CHAPTERS — shared section polish
   ---------------------------------------------------------------- */

.chapter { position: relative; overflow: clip; }

.chapter-kicker {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.chapter-kicker .rule {
  display: block;
  width: 56px;
  height: 1px;
  background: var(--accent-deep);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 1s cubic-bezier(0.22, 1, 0.36, 1) 0.2s;
}

.reveal.in .rule, .in .chapter-kicker .rule { transform: scaleX(1); }

/* Ghost chapter numeral floating behind section heads */
.ghost-index {
  position: absolute;
  top: clamp(24px, 4vw, 60px);
  right: clamp(-10px, 1vw, 40px);
  font-family: var(--font-display);
  font-size: clamp(140px, 22vw, 340px);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(190, 205, 228, 0.07);
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

/* Scroll-linked polish where the browser supports it */
@supports (animation-timeline: view()) {
  .zoom-img { overflow: hidden; }

  .zoom-img img {
    animation: img-settle linear both;
    animation-timeline: view();
    animation-range: entry 0% cover 55%;
  }

  @keyframes img-settle {
    from { transform: scale(1.14); }
    to   { transform: scale(1); }
  }

  .ghost-index {
    animation: ghost-drift linear both;
    animation-timeline: view();
    animation-range: entry 0% exit 100%;
  }

  @keyframes ghost-drift {
    from { transform: translateY(90px); }
    to   { transform: translateY(-110px); }
  }

  .chapter-dim > .container {
    animation: chapter-dim linear both;
    animation-timeline: view();
    animation-range: exit 0% exit 100%;
  }

  @keyframes chapter-dim {
    to { opacity: 0.3; transform: translateY(-24px) scale(0.985); }
  }
}

/* ----------------------------------------------------------------
   4. WHAT WE DO — sticky stacked panels
   ---------------------------------------------------------------- */

.stack {
  display: flex;
  flex-direction: column;
  gap: clamp(20px, 3vw, 36px);
}

.stack-card {
  position: sticky;
  background:
    radial-gradient(ellipse 55% 60% at 88% 0%, rgba(201, 162, 107, 0.06), transparent 60%),
    var(--bg-panel);
  border: 1px solid var(--line-strong);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  min-height: min(70vh, 620px);
  overflow: hidden;
}

.stack-card:nth-child(1) { top: calc(var(--header-h) + 16px); }
.stack-card:nth-child(2) { top: calc(var(--header-h) + 34px); }
.stack-card:nth-child(3) { top: calc(var(--header-h) + 52px); }

.stack-copy {
  position: relative;
  padding: clamp(28px, 4vw, 60px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  z-index: 1;
}

.stack-num {
  font-family: var(--font-display);
  font-size: clamp(72px, 9vw, 140px);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(201, 162, 107, 0.4);
  margin-bottom: 18px;
}

.stack-copy .service-icon { margin-bottom: 20px; }

.stack-copy h3 {
  font-family: var(--font-display);
  font-size: clamp(30px, 3.6vw, 52px);
  text-transform: uppercase;
  font-weight: 400;
  letter-spacing: 0.02em;
  margin-bottom: 16px;
}

.stack-copy > p {
  color: var(--ink-dim);
  font-size: clamp(15px, 1.4vw, 17px);
  max-width: 460px;
  margin-bottom: 24px;
}

.stack-media {
  position: relative;
  min-height: 280px;
  overflow: hidden;
}

.stack-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.02);
  transition: transform 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.stack-card:hover .stack-media img { transform: scale(1.05); }

.stack-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--bg-panel) 0%, transparent 26%);
}

.stack-media .media-tag {
  position: absolute;
  bottom: 14px;
  right: 16px;
  z-index: 1;
  color: var(--ink);
  background: rgba(11, 13, 16, 0.72);
  backdrop-filter: blur(6px);
  padding: 7px 12px;
  border: 1px solid var(--line-strong);
}

/* ----------------------------------------------------------------
   5. FEATURED WORK — clip reveal + pinned horizontal strip
   ---------------------------------------------------------------- */

.work-feature {
  margin: 0;
  position: relative;
  border: 1px solid var(--line-strong);
}

.work-feature .zoom-img {
  overflow: hidden;
  height: clamp(320px, 58vw, 620px);
}

.work-feature img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.work-feature figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 22px clamp(16px, 3vw, 32px) 18px;
  background: linear-gradient(transparent, rgba(6, 8, 11, 0.94));
  font-size: 15px;
  color: var(--ink);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 18px;
}

.work-feature figcaption .mono { color: var(--accent); }

.work-feature .feat-addr {
  font-family: var(--font-display);
  font-size: clamp(20px, 3vw, 34px);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

/* --- Horizontal strip: native scroll by default; JS pins on desktop --- */

.strip { position: relative; margin-top: clamp(40px, 6vw, 72px); }

.strip-sticky { position: relative; }

.strip-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.strip-head .mono { color: var(--accent); }

.strip-progress {
  flex: 1;
  max-width: 280px;
  height: 2px;
  background: var(--line-strong);
  overflow: hidden;
}

.strip-progress i {
  display: block;
  height: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
}

.strip-track {
  display: flex;
  gap: clamp(14px, 2vw, 24px);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 8px;
  will-change: transform;
}

.strip-track::-webkit-scrollbar { display: none; }

.strip-track figure {
  margin: 0;
  flex: none;
  width: min(72vw, 680px);
  scroll-snap-align: start;
  border: 1px solid var(--line);
  background: var(--bg-panel);
}

.strip-track .frame {
  overflow: hidden;
  aspect-ratio: 3 / 2;
}

.strip-track img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.95);
  transition: transform 1s cubic-bezier(0.22, 1, 0.36, 1);
}

.strip-track figure:hover img { transform: scale(1.04); }

.strip-track figcaption {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
}

.strip-cta {
  flex: none;
  width: min(60vw, 420px);
  scroll-snap-align: start;
  border: 1px solid var(--accent-deep);
  background:
    radial-gradient(ellipse 70% 60% at 50% 0%, rgba(201, 162, 107, 0.1), transparent 65%),
    var(--bg-raise);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 18px;
  padding: clamp(24px, 3vw, 44px);
  text-decoration: none;
}

.strip-cta strong {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(24px, 3vw, 38px);
  text-transform: uppercase;
  color: var(--ink);
  line-height: 1.05;
}

.strip-cta .mono { color: var(--accent); }

.strip-cta:hover { border-color: var(--accent); }

/* Pinned mode (JS measures & drives translateX) */
.strip.is-pinned .strip-sticky {
  position: sticky;
  top: calc(var(--header-h) + 8px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.strip.is-pinned .strip-track {
  overflow: visible;
  scroll-snap-type: none;
  padding-bottom: 0;
}

/* --- Case ledger --- */

.ledger {
  margin-top: clamp(48px, 7vw, 84px);
  border-top: 1px solid var(--line-strong);
}

.ledger-row {
  display: grid;
  grid-template-columns: minmax(120px, 0.8fr) 2fr auto;
  align-items: center;
  gap: 16px 28px;
  padding: clamp(20px, 3vw, 30px) 4px;
  border-bottom: 1px solid var(--line);
  transition: background 0.3s ease, padding-left 0.3s ease;
}

.ledger-row:hover { background: var(--bg-panel); padding-left: 16px; }

.ledger-tag { color: var(--accent); }

.ledger-line {
  font-family: var(--font-display);
  font-size: clamp(18px, 2.6vw, 32px);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--ink-dim);
  font-weight: 400;
}

.ledger-line b { color: var(--ink); font-weight: 400; }
.ledger-line .arrow { color: var(--accent); padding: 0 0.25em; }

.ledger-note { text-align: right; }

/* ----------------------------------------------------------------
   6. TRACK RECORD — oversized counters
   ---------------------------------------------------------------- */

.tr-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  position: relative;
  z-index: 1;
}

.tr-stat {
  background: var(--bg-panel);
  padding: clamp(40px, 5vw, 64px) clamp(28px, 3vw, 48px);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tr-value {
  font-family: var(--font-display);
  font-size: clamp(72px, 9vw, 128px);
  line-height: 1;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}

.tr-value .stat-plus, .tr-value .unit { color: var(--accent); }

.tr-ticks {
  height: 12px;
  margin-top: 10px;
  background: repeating-linear-gradient(90deg, var(--accent-deep) 0 1px, transparent 1px 13px);
  mask-image: linear-gradient(90deg, #000 55%, transparent);
  -webkit-mask-image: linear-gradient(90deg, #000 55%, transparent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 1.4s cubic-bezier(0.22, 1, 0.36, 1) 0.3s;
}

.tr-stat.in .tr-ticks { transform: scaleX(1); }

.tr-label {
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
  margin-top: 8px;
}

/* ----------------------------------------------------------------
   7. MENTORING — timeline + before/after sliders
   ---------------------------------------------------------------- */

.path-cine .path-step {
  transition: border-color 0.3s ease;
}

.path-cine .path-step:hover { border-top-color: var(--accent); }

.ba-deck {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(14px, 2vw, 24px);
  margin-top: clamp(40px, 5vw, 64px);
}

.ba-intro {
  margin-top: clamp(48px, 6vw, 72px);
  padding-top: 32px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px 24px;
}

.ba-intro h3 {
  font-family: var(--font-display);
  font-size: clamp(24px, 3.2vw, 40px);
  text-transform: uppercase;
  font-weight: 400;
}

.ba-intro .mono { color: var(--accent); }

/* The comparison widget */
.ba {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background: var(--bg-raise);
  --pos: 50%;
}

.ba img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.ba .ba-after {
  position: absolute;
  inset: 0;
  /* AFTER reveals on the right of the handle — matches the BEFORE/AFTER tags */
  clip-path: inset(0 0 0 var(--pos));
}

.ba .ba-divider {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos);
  width: 2px;
  margin-left: -1px;
  background: var(--accent);
  pointer-events: none;
}

.ba .ba-divider::after {
  content: "\2194";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(11, 13, 16, 0.85);
  border: 1px solid var(--accent);
  color: var(--accent);
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ba .ba-range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
  touch-action: pan-y;
  -webkit-appearance: none;
  appearance: none;
}

.ba:has(.ba-range:focus-visible) { outline: 2px solid var(--accent); outline-offset: 3px; }

.ba .ba-tag {
  position: absolute;
  top: 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  padding: 5px 9px;
  background: rgba(11, 13, 16, 0.78);
  border: 1px solid var(--line-strong);
  color: var(--ink);
  pointer-events: none;
}

.ba .ba-tag.t-before { left: 10px; }
.ba .ba-tag.t-after { right: 10px; color: var(--accent); border-color: var(--accent-deep); }

.ba-card figcaption {
  padding: 12px 2px 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ba-card figcaption .addr {
  font-family: var(--font-display);
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--ink);
}

.ba-card { margin: 0; }

/* ----------------------------------------------------------------
   8. CONTACT chapter
   ---------------------------------------------------------------- */

.contact-cine .contact-title { font-size: clamp(64px, 11vw, 150px); }

/* ----------------------------------------------------------------
   9. FOOTER — polished
   ---------------------------------------------------------------- */

.footer-cine { padding: 0; }

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: clamp(28px, 4vw, 56px);
  padding: clamp(48px, 6vw, 72px) 0 clamp(36px, 5vw, 56px);
}

.footer-brand .brand-mark { width: 36px; height: 36px; margin-bottom: 16px; }

.footer-brand p {
  color: var(--ink-dim);
  font-size: 14px;
  max-width: 280px;
  margin-top: 10px;
}

.footer-brand .brand-name { font-size: 21px; display: block; }

.footer-col h4 {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 18px;
}

.footer-col ul { list-style: none; }

.footer-col li { margin-bottom: 10px; }

.footer-col a {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s ease, padding-left 0.2s ease;
}

.footer-col a:hover { color: var(--accent); padding-left: 6px; }

.footer-bar {
  border-top: 1px solid var(--line);
  padding: 22px 0;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

/* ----------------------------------------------------------------
   10. Responsive
   ---------------------------------------------------------------- */

@media (max-width: 960px) {
  .stack-card {
    grid-template-columns: 1fr;
    min-height: 0;
    position: relative;
    top: auto !important;
  }

  .stack-media { min-height: 240px; order: -1; }
  .stack-media::after { background: linear-gradient(180deg, transparent 55%, var(--bg-panel)); }

  .ba-deck { grid-template-columns: 1fr; max-width: 560px; }

  .tr-grid { grid-template-columns: 1fr; }

  .ledger-row { grid-template-columns: 1fr; gap: 6px; }
  .ledger-note { text-align: left; }

  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .hero-title-cine { font-size: clamp(52px, 15vw, 78px); }
  .hero-title-cine .word.outline { margin-left: 10vw; }
  .footer-grid { grid-template-columns: 1fr; }
  .strip-track figure { width: 84vw; }
  .strip-cta { width: 78vw; }
}

/* ----------------------------------------------------------------
   11. Reduced motion — kill the cinema, keep the content
   ---------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  .grain::before,
  .hero-aurora,
  .hero-cine .hero-keystone,
  .mq-track { animation: none !important; }

  html.js .hero-skyline path,
  html.js .hero-keystone path,
  html.js .hero-keystone line,
  html.js .hero-keystone circle {
    animation: none !important;
    stroke-dasharray: none;
    stroke-dashoffset: 0;
  }

  html.js .hero-skyline line { animation: none !important; opacity: 0.6; }

  html.js .hero-title-cine .word,
  html.js .hero-fade {
    animation: none !important;
    transform: none;
    opacity: 1;
  }

  .fx-wipe { clip-path: none; transition: none; }
  .fx-scale { opacity: 1; transform: none; transition: none; }
  .tr-ticks { transform: scaleX(1); transition: none; }
  .chapter-kicker .rule { transform: scaleX(1); transition: none; }
  [data-magnetic] { transition: none; }
  .cursor-glow { display: none; }
  .zoom-img img { animation: none !important; }
  .ghost-index { animation: none !important; }
  .chapter-dim > .container { animation: none !important; }
  .strip.is-pinned .strip-sticky { position: relative; top: auto; }
  .pscr-live i { animation: none !important; }
}

/* ----------------------------------------------------------------
   THE PORTAL — client differentiator interlude
   ---------------------------------------------------------------- */
.portal-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(32px, 6vw, 88px);
  align-items: center;
}
.portal-list {
  list-style: none;
  margin: 34px 0 30px;
  padding: 0;
  display: grid;
  gap: 18px;
}
.portal-list li { display: flex; gap: 16px; align-items: flex-start; }
.portal-list li > span { color: var(--accent); font-size: 0.8rem; padding-top: 3px; min-width: 22px; }
.portal-list li b { display: block; margin-bottom: 3px; color: var(--ink); font-size: 1rem; }
.portal-list li div { color: var(--ink-dim); font-size: 0.95rem; line-height: 1.5; }

/* phone mock */
.portal-device { display: flex; flex-direction: column; align-items: center; }
.phone {
  position: relative;
  width: min(300px, 78vw);
  aspect-ratio: 9 / 19;
  background: #0a0f18;
  border: 2px solid var(--line-strong);
  border-radius: 40px;
  padding: 14px 12px;
  box-shadow: 0 40px 80px -30px rgba(0,0,0,0.8), inset 0 0 0 1px rgba(255,255,255,0.04);
}
.phone-notch {
  position: absolute; top: 14px; left: 50%; transform: translateX(-50%);
  width: 42%; height: 22px; background: #0a0f18; border-radius: 0 0 14px 14px; z-index: 2;
}
.phone-screen {
  height: 100%; border-radius: 28px; overflow: hidden;
  background: var(--bg-panel); border: 1px solid var(--line);
  padding: 26px 14px 16px; display: flex; flex-direction: column; gap: 10px;
}
.pscr-head { display: flex; justify-content: space-between; align-items: center; font-size: 0.62rem; letter-spacing: 0.08em; color: var(--ink); font-family: var(--font-mono); }
.pscr-live { color: var(--accent); display: inline-flex; align-items: center; gap: 5px; font-family: var(--font-mono); font-size: 0.6rem; }
.pscr-live i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); animation: pscr-pulse 1.6s ease-in-out infinite; }
@keyframes pscr-pulse { 0%,100%{opacity:1} 50%{opacity:0.25} }
.pscr-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.pscr-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 5px; }
.pscr-bar { display: grid; grid-template-columns: 62px 1fr; align-items: center; gap: 8px; font-size: 0.6rem; color: var(--ink-dim); font-family: var(--font-mono); }
.pscr-bar i { height: 6px; border-radius: 4px; background: var(--line-strong); position: relative; overflow: hidden; }
.pscr-bar i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--p); background: linear-gradient(90deg, var(--accent-deep), var(--accent)); border-radius: 4px; }
.pscr-foot { margin-top: auto; display: flex; justify-content: space-between; font-size: 0.58rem; color: var(--ink-dim); font-family: var(--font-mono); padding-top: 8px; border-top: 1px solid var(--line); }
.portal-cap { margin-top: 16px; font-size: 0.62rem; letter-spacing: 0.08em; color: var(--ink-dim); }

@media (max-width: 820px) {
  .portal-grid { grid-template-columns: 1fr; }
  .portal-device { order: -1; }
}

/* ----------------------------------------------------------------
   757 TRANSFORMATION — side-by-side before/after
   ---------------------------------------------------------------- */
.ba757 { display: grid; gap: 26px; margin-top: 40px; }
.ba-row { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 5px; }
.ba-shot { position: relative; overflow: hidden; aspect-ratio: 4 / 3; border: 1px solid var(--line-strong); background: var(--bg-panel); }
.ba-shot img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.6s ease; }
.ba-row:hover .ba-shot img { transform: scale(1.03); }
.ba-chip {
  position: absolute; top: 10px; left: 10px;
  font-family: var(--font-mono); font-size: 0.58rem; letter-spacing: 0.12em;
  padding: 3px 9px; border-radius: 3px;
}
.ba-chip.before { background: rgba(11,13,16,0.82); color: var(--ink-dim); border: 1px solid var(--line-strong); }
.ba-chip.after { background: var(--accent); color: #0b0d10; font-weight: 700; }
.ba-cap {
  grid-column: 1 / -1; margin-top: 10px;
  font-size: 0.62rem; letter-spacing: 0.14em; color: var(--ink-dim); text-align: center;
}
@media (max-width: 720px) {
  .ba-row { grid-template-columns: 1fr; gap: 5px; }
}

/* 757 deal-math strip */
.deal-strip {
  display: flex; flex-wrap: wrap; gap: 2px;
  margin-top: 32px; border: 1px solid var(--line-strong);
}
.deal-strip > div {
  flex: 1 1 130px; padding: 16px 18px; background: var(--bg-panel);
  display: flex; flex-direction: column; gap: 6px;
}
.deal-strip .mono { font-size: 0.58rem; letter-spacing: 0.14em; color: var(--ink-dim); }
.deal-strip b { font-family: var(--font-display); font-size: clamp(1.3rem, 3vw, 1.9rem); color: var(--ink); font-weight: 400; }
.deal-strip .deal-hi b { color: var(--accent); }
.deal-strip .deal-hi { background: linear-gradient(180deg, rgba(201,162,107,0.08), transparent); }
