/* ==========================================================================
   AppanDesign — Components (Averix system)
   Every repeated UI object, ordered roughly by where it appears on a page.
   Components read semantic tokens only, so each one works on light and dark
   bands without a second rule set.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Custom cursor
   -------------------------------------------------------------------------- */
.cursor-dot {
  position: fixed;
  left: 0; top: 0;
  width: 10px; height: 10px;
  margin: -5px 0 0 -5px;
  border-radius: 50%;
  border: 1px solid var(--amber);
  background: rgba(236, 176, 20, 0.2);
  z-index: 9999;
  pointer-events: none;
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    width 0.45s var(--ease),
    height 0.45s var(--ease),
    margin 0.45s var(--ease),
    background 0.45s var(--ease),
    opacity 0.3s linear;
}
.cursor-dot.is-labelled { background: var(--amber); }
.cursor-dot__label {
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: var(--weight-semibold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.3s linear;
}
.cursor-dot.is-labelled .cursor-dot__label { opacity: 1; }

@media (hover: none), (prefers-reduced-motion: reduce) {
  .cursor-dot { display: none !important; }
}

/* --------------------------------------------------------------------------
   2. Page transition curtain
   -------------------------------------------------------------------------- */
.curtain {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: var(--ink);
  transform: scaleY(1);
  transform-origin: 50% 0%;
  /* Delay the visibility switch until AFTER the reveal transform finishes: the
     open animation still plays, then this full-viewport dark layer drops out of
     rendering. Otherwise iOS Safari (Liquid Glass) keeps tinting its top/bottom
     bars black from this element, since it sits at every viewport edge. */
  transition: transform 0.62s var(--ease-inout), visibility 0s linear 0.62s;
}
.curtain.is-open {
  transform: scaleY(0);
  visibility: hidden;
  pointer-events: none;
}
.curtain.is-closing {
  transform-origin: 50% 100%;
  transform: scaleY(1);
  visibility: visible;
  transition: transform 0.62s var(--ease-inout);
  pointer-events: auto;
}
@media (prefers-reduced-motion: reduce) { .curtain { display: none; } }

/* --------------------------------------------------------------------------
   3. Navigation — Averix lockup left, white capsule right
   -------------------------------------------------------------------------- */
.nav {
  position: fixed;
  /* viewport-fit=cover lets the hero paint into the notch area, so offset the
     nav by the safe-area inset to keep it clear of the status bar. */
  top: calc(30px + env(safe-area-inset-top, 0px));
  left: 0;
  right: 0;
  z-index: 900;
  height: var(--nav-h);
  padding-inline: var(--gutter-nav);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  pointer-events: none;   /* the bar itself is a spacer; children take clicks */
}
.nav > * { pointer-events: auto; min-width: 0; }

/* iOS status-bar strip. With viewport-fit=cover the page paints under the notch,
   so fill that strip with black on every page — the hero then reads edge-to-edge
   and Safari tints its top bar to match. Only the TOP is touched; the bottom bar
   is left alone to behave as it always has. */
.nav::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: env(safe-area-inset-top, 0px);
  background: #000;
  pointer-events: none;
}

@media (max-width: 700px) {
  .nav { top: calc(14px + env(safe-area-inset-top, 0px)); height: 64px; }
}

/* -- Brand lockup -- */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);            /* the inlined mark paints with currentColor */
}
.brand__mark {
  height: clamp(26px, 2.2vw, 36px);
  width: auto;
  aspect-ratio: 1;              /* the stack mark is square */
  flex-shrink: 0;
}
.brand__name {
  font-family: var(--font-brand);   /* Funnel Display */
  font-weight: 600;
  font-size: clamp(18px, 1.8vw, 32px);
  line-height: 1;
  letter-spacing: -0.045em;
  color: currentColor;
  white-space: nowrap;
}
/* Only the nav lockup drops its wordmark on the narrowest screens — the
   footer and contact rail have the room for it. */
@media (max-width: 420px) {
  .nav .brand__name { display: none; }
}
/* The lockup floats outside the capsule, so it follows the band behind it:
   white over any dark band, ink over the light page. motion.js keeps
   `nav--on-dark` in sync while scrolling. */
.nav .brand { color: var(--ink); }
.nav--over-dark .brand,
.nav--on-dark .brand { color: var(--white); }

/* Anywhere on a dark band — footer, contact rail on the ink page */
.is-dark .brand,
.footer .brand { color: var(--white); }

/* Desktop: the logo sits in its own solid white capsule, matching the nav
   capsule, so it reads the same over the dark hero and the light page.
   (Phones/tablets already have the glass pill — see the 1079px rules.) */
@media (min-width: 1080px) {
  .nav .brand {
    height: var(--nav-h);
    padding: 0 26px 0 18px;
    gap: 12px;
    border-radius: var(--radius-nav);
    /* Frosted glass, same recipe as the phone pills. */
    background: rgba(255, 255, 255, 0.62);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
    color: var(--ink);
    box-shadow: var(--ring-nav), var(--shadow-nav);
    transition: background var(--duration-base) var(--ease), color var(--duration-base) var(--ease), box-shadow var(--duration-base) var(--ease);
  }
  /* Over a dark band (hero, services, CTA): dark glass with white lockup. */
  .nav--over-dark .brand,
  .nav--on-dark .brand {
    background: rgba(15, 15, 15, 0.62);
    color: var(--white);
    box-shadow: inset 0 0 0 1px var(--white-a20), var(--shadow-nav);
  }
  @supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .nav .brand { background: rgba(255, 255, 255, 0.92); }
    .nav--over-dark .brand,
    .nav--on-dark .brand { background: rgba(15, 15, 15, 0.92); }
  }
}

.brand__dot { color: var(--amber); }
/* The giant wordmark is painted via background-clip:text, so the dot needs
   its own amber fill clipped to the glyph — a plain `color` is ignored there. */
.wordmark__dot {
  color: var(--amber);
  background: var(--amber);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.brand__text { display: grid; gap: 3px; }
.brand__tag {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: clamp(7px, 0.55vw, 9px);
  line-height: 1;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: currentColor;
  opacity: 0.55;
  white-space: nowrap;
}
.brand--sm .brand__tag { font-size: 7px; }
.brand--sm .brand__mark { height: 28px; }
.brand--sm .brand__name { font-size: 22px; }

/* -- The capsule -- */
.nav__capsule {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  height: var(--nav-h);
  border-radius: var(--radius-nav);
  background: var(--white);   /* solid on desktop; glass only on mobile (below) */
  box-shadow: var(--ring-nav), var(--shadow-nav);
  padding: 14px 14px 14px 30px;
  transition: background var(--duration-base) var(--ease);
}
/* No backdrop-filter support → fall back to a near-solid white so it stays legible. */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .nav__capsule { background: rgba(255, 255, 255, 0.92); }
}
/* Mobile / tablet: the capsule holds only the burger, so make it a single
   clean circle (no nested ring) that matches the logo pill's height. */
@media (max-width: 1079px) {
  .nav__capsule {
    width: var(--nav-h);
    height: var(--nav-h);
    padding: 0;
    justify-content: center;
    /* Frosted glass on mobile only. */
    background: rgba(255, 255, 255, 0.62);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
  }
  .nav__capsule .burger { box-shadow: none; width: 100%; height: 100%; }
}
@media (max-width: 700px) {
  .nav__capsule { width: 64px; height: 64px; }
}

.nav__links {
  display: none;
  align-items: center;
  gap: clamp(20px, 2.6vw, 50px);
  margin-right: clamp(20px, 2.6vw, 50px);
}
.nav__link {
  font-family: var(--font-body);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body);
  line-height: 1;
  color: var(--ink);
  opacity: 0.7;
  white-space: nowrap;
  transition: opacity var(--duration-fast) var(--ease), color var(--duration-fast) var(--ease);
}
.nav__link:hover { opacity: 1; }
.nav__link[aria-current="page"] { opacity: 1; color: var(--ink); }
.nav__link[aria-current="page"]::after {
  content: "";
  display: block;
  height: 2px;
  margin-top: 6px;
  background: var(--amber);
  border-radius: 2px;
}

/* Specificity must beat `.btn { display: inline-flex }` defined further down. */
.nav .nav__cta { display: none; }

/* Burger — the 44px mark in the Averix capsule */
.burger {
  width: 44px; height: 44px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  box-shadow: var(--ring-nav);
  transition: background var(--duration-fast) var(--ease);
  flex-shrink: 0;
}
.burger:hover { background: var(--off-f5); }
.burger__bar {
  display: block;
  width: 16px; height: 2px;
  border-radius: 2px;
  background: var(--ink);
}

@media (min-width: 1080px) {
  .nav__links { display: flex; }
  .nav .nav__cta { display: inline-flex; margin-left: 6px; }
  .burger { display: none; }
}

/* --------------------------------------------------------------------------
   4. Full-screen menu
   -------------------------------------------------------------------------- */
.menu {
  position: fixed;
  inset: 0;
  z-index: 950;
  /* Solid opaque dark (no backdrop-filter): on a light site iOS Safari reads a
     blurred/translucent overlay at the edges and keeps the top/bottom bars
     light. A solid dark fill makes Safari tint both bars black → the menu
     covers the full screen, notch and home-indicator included. */
  background: var(--ink);
  color: var(--white);
  /* Instant show/hide like appandesign.com — no fade, slide or stagger, so it
     can never hang or show the page through it. */
  display: none;
  flex-direction: column;
  justify-content: flex-start;
  gap: clamp(32px, 6vw, 56px);
  padding: clamp(96px, 22vw, 130px) clamp(24px, 7vw, 60px) clamp(40px, 8vw, 64px);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.menu.is-open { display: flex; }

.menu__close {
  position: absolute;
  top: clamp(18px, 4vw, 30px);
  right: clamp(24px, 7vw, 60px);
  width: 52px; height: 52px;
  border-radius: 50%;
  font-size: 18px;
  color: var(--white);
  box-shadow: inset 0 0 0 1px var(--white-a20);
  transition: background var(--duration-fast) var(--ease);
}
.menu__close:hover { background: rgba(255, 255, 255, 0.08); }

/* Numbered nav list — styled like the appandesign.com mobile menu. */
.menu__list { display: flex; flex-direction: column; }
.menu__link {
  display: flex;
  align-items: baseline;
  gap: 18px;
  padding: 14px 0;
  border-bottom: 1px solid var(--white-a20);
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  font-size: clamp(32px, 9vw, 54px);
  line-height: 1.05;
  letter-spacing: var(--track-tight);
  color: var(--white);
  transition: color 0.18s var(--ease), padding-left 0.25s var(--ease);
}
.menu__link:hover,
.menu__link.is-active { padding-left: 10px; }
.menu__num {
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: var(--weight-semibold);
  letter-spacing: 0.16em;
  color: var(--white-a50);
  min-width: 26px;
}

/* Contact footer — email, phone, availability. */
.menu__foot {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: auto;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--gray-c5);
}
.menu__foot a { color: var(--white); }
.menu__foot a:hover { color: var(--amber); }
.menu__status { display: inline-flex; align-items: center; gap: 10px; color: var(--gray-c5); }
.menu__dot { width: 9px; height: 9px; border-radius: 50%; background: #31d07f; flex: none; }

/* --------------------------------------------------------------------------
   5. Buttons — Averix pill with the white knob and 45° arrow
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 8px 8px 32px;
  border-radius: var(--radius-button);
  background: var(--action-fill);
  color: var(--action-text);
  font-family: var(--font-ui);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body);
  line-height: 1.45;
  letter-spacing: var(--track-snug);
  white-space: nowrap;
  width: fit-content;
  transition:
    background var(--duration-base) var(--ease),
    color var(--duration-base) var(--ease),
    box-shadow var(--duration-base) var(--ease),
    opacity var(--duration-fast) var(--ease);
}
.btn__knob {
  position: relative;
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--action-knob);
  flex-shrink: 0;
  display: grid;
  place-items: center;
  transition: background var(--duration-base) var(--ease), transform var(--duration-base) var(--ease);
}
.btn__knob svg { width: 11px; height: 11px; overflow: visible; }
.btn__knob path { fill: var(--action-glyph); transition: fill var(--duration-base) var(--ease); }
.btn:hover .btn__knob { transform: translate(2px, -2px); }

/* Amber — the primary action */
.btn--amber { background: var(--amber); color: var(--ink); }
.btn--amber .btn__knob { background: var(--ink); }
.btn--amber .btn__knob path { fill: var(--amber); }
.btn--amber:hover { background: var(--ink); color: var(--white); }
.btn--amber:hover .btn__knob { background: var(--amber); }
.btn--amber:hover .btn__knob path { fill: var(--ink); }

/* Outline — ink hairline, fills on hover */
.btn--outline {
  background: transparent;
  color: var(--text-heading);
  box-shadow: var(--ring-pill);
}
.btn--outline .btn__knob { background: var(--action-fill); }
.btn--outline .btn__knob path { fill: var(--action-text); }
.btn--outline:hover { background: var(--action-fill); color: var(--action-text); }
.btn--outline:hover .btn__knob { background: var(--action-text); }
.btn--outline:hover .btn__knob path { fill: var(--action-fill); }

.btn--sm { padding: 10px 10px 10px 26px; font-size: var(--size-body-sm); }
.btn--sm .btn__knob { width: 36px; height: 36px; }
.btn--nav { padding: 6px 6px 6px 24px; font-size: var(--size-body-sm); }
.btn--nav .btn__knob { width: 40px; height: 40px; }

/* Round icon button (carousel arrows) */
.icon-btn {
  width: 52px; height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 16px;
  color: var(--text-heading);
  box-shadow: var(--ring-pill);
  transition: background var(--duration-fast) var(--ease), color var(--duration-fast) var(--ease);
}
.icon-btn:hover { background: var(--action-fill); color: var(--action-text); }

/* Underlined text link */
.link-rule {
  display: inline-block;
  font-family: var(--font-ui);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-hair);
  padding-bottom: 3px;
}
.link-rule:hover { color: var(--amber); border-color: var(--amber); }

/* --------------------------------------------------------------------------
   6. Hero furniture
   -------------------------------------------------------------------------- */
.hero__media { position: absolute; inset: -6% -4%; z-index: 0; }
.hero__scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  /* Left-to-right veil for headline contrast (darkest on the lower-left where
     the title sits), fading out before the subject on the right — layered over
     the vertical top/bottom scrim. */
  background:
    linear-gradient(
      100deg,
      rgba(15, 15, 15, 0.80) 0%,
      rgba(15, 15, 15, 0.52) 32%,
      rgba(15, 15, 15, 0.00) 62%
    ),
    linear-gradient(
      180deg,
      rgba(15, 15, 15, 0.74) 0%,
      rgba(15, 15, 15, 0.40) 34%,
      rgba(15, 15, 15, 0.66) 58%,
      rgba(15, 15, 15, 0.88) 84%,
      var(--ink) 100%
    );
}
.hero__scrim--soft {
  background: linear-gradient(180deg, rgba(15, 15, 15, 0.7) 0%, rgba(15, 15, 15, 0.35) 45%, var(--ink) 100%);
}
.hero__vignette {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(120% 80% at 50% 100%, rgba(15, 15, 15, 0.72), transparent 62%);
}
.hero__inner {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
}
.hero__stack { display: flex; flex-direction: column; gap: clamp(20px, 2.6vw, 40px); }
.hero__foot {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(24px, 5vw, 80px);
  align-items: flex-end;
  justify-content: space-between;
  border-top: 1px solid var(--border-hair);
  padding-top: clamp(20px, 2.4vw, 40px);
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* Amber rule + diamond that float in hero corners */
.deco-rule {
  position: absolute;
  z-index: 2;
  height: 1px;
  width: clamp(120px, 15vw, 230px);
  background: linear-gradient(90deg, transparent, var(--amber));
  pointer-events: none;
}
.deco-rule--hero { top: 32%; right: clamp(20px, 6vw, 90px); }
.deco-rule--page { top: 24%; right: 6%; width: clamp(90px, 12vw, 190px); }
.deco-diamond {
  position: absolute;
  z-index: 2;
  top: 26%;
  right: clamp(20px, 6vw, 90px);
  width: 8px; height: 8px;
  border: 1px solid var(--amber);
  transform: rotate(45deg);
  pointer-events: none;
}

/* Isometric wireframe */
.iso {
  position: absolute;
  z-index: 2;
  pointer-events: none;
  aspect-ratio: 1;
  opacity: 0.9;
}
.iso--hero { top: 14%; right: clamp(40px, 12vw, 200px); width: clamp(120px, 16vw, 260px); }
.iso--page { top: 18%; right: clamp(40px, 10vw, 160px); width: clamp(100px, 14vw, 220px); opacity: 0.8; }
.iso__inner {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: transform 0.9s var(--ease-out);
}
.iso__plate {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(236, 176, 20, 0.55);
  transform: rotateX(60deg) rotateZ(45deg);
}
.iso__plate--2 { inset: 12%; border-color: var(--gray-a30); transform: rotateX(60deg) rotateZ(45deg) translateZ(40px); }
.iso__plate--3 { inset: 24%; border-color: rgba(236, 176, 20, 0.35); transform: rotateX(60deg) rotateZ(45deg) translateZ(80px); }
.iso__core {
  position: absolute;
  left: 50%; top: 50%;
  width: 6px; height: 6px;
  margin: -3px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 40px 10px rgba(236, 176, 20, 0.35);
}

/* Scroll cue */
.scroll-cue {
  position: absolute;
  left: 50%; bottom: 14px;
  z-index: 3;
  width: 1px; height: 30px;
  overflow: hidden;
  pointer-events: none;
}
.scroll-cue span {
  display: block;
  width: 1px; height: 30px;
  background: linear-gradient(180deg, var(--amber), transparent);
  animation: ad-scrollcue 2.4s var(--ease) infinite;
}

/* --------------------------------------------------------------------------
   7. Image slots
   -------------------------------------------------------------------------- */
.img-slot {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: inherit;
  background: var(--surface-muted);
}
.is-dark .img-slot { background: var(--ink-1e); }
.img-slot__img { width: 100%; height: 100%; object-fit: cover; display: block; }
.img-slot--rounded { border-radius: var(--radius-card); }
.img-slot__ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
  font-family: var(--font-ui);
  font-size: var(--size-body-sm);
  color: var(--text-faint);
  box-shadow: inset 0 0 0 1px var(--border-field);
}

.frame { position: relative; overflow: hidden; border-radius: var(--radius-card); }
.frame--4x3   { aspect-ratio: 4 / 3; }
.frame--3x4   { aspect-ratio: 3 / 4; }
.frame--1x1   { aspect-ratio: 1 / 1; }
.frame--4x5   { aspect-ratio: 4 / 5; min-height: 240px; }
.frame--5x4   { aspect-ratio: 5 / 4; }
.frame--9x16  { aspect-ratio: 9 / 16; max-width: 320px; margin-inline: auto; }
.frame--16x9  { aspect-ratio: 16 / 9; min-height: 260px; }
.frame--16x10 { aspect-ratio: 16 / 10; }
.frame--21x9  { aspect-ratio: 21 / 9; min-height: 240px; }
.frame--flat  { border-radius: 0; }

/* --------------------------------------------------------------------------
   8. Work cards
   -------------------------------------------------------------------------- */
.work { display: flex; flex-direction: column; gap: 20px; cursor: pointer; }
.work__media {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-card);
  transition: transform 1.1s var(--ease-out);
}
.work__zoom { position: absolute; inset: 0; transition: transform 1.1s var(--ease-out); }
.work__body { transition: transform 0.9s var(--ease-out); }
.work__index {
  font-family: var(--font-accent);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  letter-spacing: 0.16em;
  color: var(--amber);
}
.work__title {
  margin: 10px 0 8px;
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h3);
  line-height: var(--lh-h3);
  letter-spacing: var(--track-snug);
  color: var(--text-heading);
}
.work__title--lg { font-size: var(--size-h2); line-height: var(--lh-h2); }
.work__desc { margin-top: 14px; }
.work__arrow {
  display: grid;
  place-items: center;
  width: 52px; height: 52px;
  border-radius: 50%;
  flex-shrink: 0;
  font-size: 18px;
  color: var(--text-heading);
  box-shadow: var(--ring-pill);
  transition: background var(--duration-base) var(--ease), color var(--duration-base) var(--ease), transform var(--duration-base) var(--ease);
}
.work__rule {
  height: 1px;
  background: var(--amber);
  width: 0;
  transition: width 1s var(--ease-out);
}
.work__tag {
  position: absolute;
  left: 18px; bottom: 18px;
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  font-family: var(--font-ui);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  color: var(--ink);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity var(--duration-slow) var(--ease), transform var(--duration-slow) var(--ease);
  pointer-events: none;
}

.work:hover .work__zoom,
.work:focus-within .work__zoom { transform: scale(1.035); }
.work:hover .work__body,
.work:focus-within .work__body { transform: translateX(12px); }
.work:hover .work__arrow,
.work:focus-within .work__arrow {
  background: var(--amber);
  color: var(--ink);
  transform: translate(4px, -4px);
}
.work:hover .work__rule,
.work:focus-within .work__rule { width: 100%; }
.work:hover .work__tag,
.work:focus-within .work__tag { opacity: 1; transform: none; }

/* --------------------------------------------------------------------------
   9. Accordion (services, FAQ)
   -------------------------------------------------------------------------- */
.acc { border-top: 1px solid var(--border-hair); }
.acc__item { border-bottom: 1px solid var(--border-hair); }
.acc__head {
  width: 100%;
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 48px);
  padding: clamp(22px, 2.6vw, 40px) 0;
  text-align: left;
}
.acc__head--lg { padding-block: clamp(24px, 3vw, 48px); }
.acc__num {
  font-family: var(--font-accent);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  letter-spacing: 0.14em;
  color: var(--amber);
  min-width: 34px;
}
.acc__title {
  flex: 1;
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h2);
  line-height: var(--lh-h2);
  letter-spacing: var(--track-snug);
  color: var(--text-heading);
  transition: color var(--duration-base) var(--ease), transform var(--duration-slow) var(--ease);
}
.acc__title--lg { font-size: var(--size-h1); line-height: var(--lh-h1); }
.acc__title--plain {
  font-family: var(--font-display);
  font-size: var(--size-h4);
  line-height: var(--lh-h4);
}
.acc__head:hover .acc__title { color: var(--amber); transform: translateX(10px); }
.acc__icon {
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  font-size: 20px;
  color: var(--text-heading);
  box-shadow: var(--ring-pill);
  transition: transform var(--duration-slow) var(--ease), background var(--duration-base) var(--ease), color var(--duration-base) var(--ease);
}
.acc__panel {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.9s var(--ease), opacity 0.7s var(--ease);
}
.acc__panel-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: clamp(20px, 3vw, 48px);
  padding: 0 0 clamp(30px, 3.4vw, 52px) clamp(0px, 3vw, 82px);
}
.acc__item[data-open] .acc__title { color: var(--amber); }
.acc__item[data-open] .acc__icon {
  transform: rotate(135deg);
  background: var(--amber);
  color: var(--ink);
}
.acc__head--faq { gap: 20px; padding-block: 22px; }
.acc__answer { margin-bottom: 24px; max-width: 58ch; }
.acc__lede { font-size: var(--size-body-lg); line-height: var(--lh-lead); color: var(--text-strong); }

/* Label + copy pair */
.deflist__label {
  display: block;
  font-family: var(--font-ui);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--amber);
}
.deflist__label--muted { color: var(--text-muted); }
.deflist__value {
  margin-top: 12px;
  font-family: var(--font-body);
  font-size: var(--size-body-sm);
  line-height: var(--lh-loose);
  color: var(--text-body);
}
.deflist__value--lede { font-size: var(--size-body-lg); color: var(--text-strong); }
.deflist--wide { grid-column: 1 / -1; max-width: 66ch; }

/* --------------------------------------------------------------------------
   10. Expanding rows (industries)
   -------------------------------------------------------------------------- */
.row-item {
  border-bottom: 1px solid var(--border-hair);
  padding: clamp(20px, 2.4vw, 36px) 0;
  cursor: pointer;
  transition: padding-left var(--duration-slow) var(--ease);
}
.row-item:hover { padding-left: 18px; }
.row-item__title {
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h2);
  line-height: var(--lh-h2);
  letter-spacing: var(--track-snug);
  color: var(--text-heading);
  transition: color var(--duration-base) var(--ease);
}
.row-item:hover .row-item__title { color: var(--amber); }
.row-item__icon {
  color: var(--amber);
  font-size: 20px;
  transition: transform var(--duration-slow) var(--ease);
}
.row-item:hover .row-item__icon { transform: translateX(10px); }
.row-item__panel {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.8s var(--ease), opacity 0.7s var(--ease);
}
.row-item__panel p { margin-top: 16px; }

/* --------------------------------------------------------------------------
   11. Pricing cards
   -------------------------------------------------------------------------- */
.tier {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: clamp(20px, 3vw, 56px);
  padding: clamp(32px, 3.6vw, 64px);
  border-radius: var(--radius-card);
  box-shadow: var(--ring-card);
  background: var(--surface-card);
  transition: box-shadow var(--duration-base) var(--ease), transform var(--duration-base) var(--ease);
}
.tier:hover { box-shadow: var(--shadow-card), var(--ring-card); transform: translateY(-4px); }
.tier--featured {
  background: var(--ink);
  color: var(--white);
  --text-heading: var(--white);
  --text-body: var(--gray-c5);
  --text-muted: var(--white-a50);
  --text-strong: var(--white);
  --border-hair: var(--white-a20);
  --action-fill: var(--white);
  --action-text: var(--ink);
  --action-knob: var(--ink);
  --action-glyph: var(--white);
}
.tier__num {
  font-family: var(--font-accent);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  letter-spacing: 0.16em;
  color: var(--amber);
}
.tier__name {
  margin: 14px 0 18px;
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h2);
  line-height: var(--lh-h2);
  letter-spacing: var(--track-snug);
  color: var(--text-heading);
  transition: color var(--duration-base) var(--ease);
}
.tier__name--featured { color: var(--amber); }
.tier__label {
  font-family: var(--font-ui);
  font-size: var(--size-body-sm);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}
.tier__price {
  margin-top: 6px;
  font-family: var(--font-accent);
  font-weight: var(--weight-bold);
  font-size: var(--size-h2);
  line-height: 1.1;
  color: var(--text-heading);
}
.tier__pitch {
  font-family: var(--font-body);
  font-size: var(--size-body-lg);
  line-height: var(--lh-lead);
  color: var(--text-body);
  max-width: 36ch;
}
.tier__list {
  margin-top: 12px;
  font-family: var(--font-body);
  font-size: var(--size-body-sm);
  line-height: 2;
  color: var(--text-body);
}
.tier__action { display: flex; align-items: flex-start; }

/* --------------------------------------------------------------------------
   12. Stats
   -------------------------------------------------------------------------- */
.stat__value {
  font-family: var(--font-accent);
  font-weight: var(--weight-bold);
  font-size: var(--size-display);
  line-height: 1;
  letter-spacing: var(--track-tight);
  color: var(--text-heading);
}
.stat__value--sm { font-size: var(--size-h1); }
.stat__label {
  margin-top: 14px;
  font-family: var(--font-ui);
  font-weight: var(--weight-medium);
  font-size: var(--size-body-sm);
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   13. Process tiles & timeline
   -------------------------------------------------------------------------- */
.step {
  padding: clamp(26px, 3vw, 48px);
  border-radius: var(--radius-card);
  box-shadow: var(--ring-panel);
  transition: background var(--duration-base) var(--ease), box-shadow var(--duration-base) var(--ease);
}
.step:hover { background: var(--surface-muted); box-shadow: var(--ring-card); }
.is-dark .step:hover { background: var(--ink-18); }
.step__num {
  font-family: var(--font-accent);
  font-weight: var(--weight-bold);
  font-size: var(--size-h4);
  color: var(--amber);
}
.step__title { margin: 14px 0 12px; }

.timeline { position: relative; padding-left: 40px; }
.timeline__track { position: absolute; left: 0; top: 0; bottom: 0; width: 1px; background: var(--border-hair); }
.timeline__bar { position: absolute; left: 0; top: 0; width: 1px; height: 0; background: var(--amber); transition: height 0.3s linear; }
.timeline__step {
  position: relative;
  padding-bottom: clamp(36px, 4vw, 64px);
  opacity: 0.35;
  transition: opacity var(--duration-slow) var(--ease);
}
.timeline__step:last-child { padding-bottom: 0; }
.timeline__step.is-active { opacity: 1; }
.timeline__dot {
  position: absolute;
  left: -44px; top: 8px;
  width: 9px; height: 9px;
  border: 1px solid var(--amber);
  border-radius: 50%;
  transition: background var(--duration-base) var(--ease);
}
.timeline__step.is-active .timeline__dot { background: var(--amber); }
.timeline__title { margin: 10px 0; font-size: var(--size-h3); line-height: var(--lh-h3); }

/* --------------------------------------------------------------------------
   14. Testimonials
   -------------------------------------------------------------------------- */
.quotes { position: relative; min-height: clamp(260px, 30vw, 340px); }
.quote {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: opacity 1s var(--ease), transform 1.1s var(--ease);
}
.quote.is-active { opacity: 1; transform: none; pointer-events: auto; }
.quote__text {
  font-family: var(--font-body);
  font-size: var(--size-quote);
  line-height: var(--lh-quote);
  letter-spacing: var(--track-snug);
  color: var(--text-heading);
  max-width: 34ch;
}
.quote__by {
  margin-top: clamp(20px, 2.2vw, 36px);
  font-family: var(--font-ui);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  color: var(--amber);
}
.quotes__nav { display: flex; gap: 12px; margin-top: clamp(24px, 3vw, 44px); }

/* --------------------------------------------------------------------------
   15. Marquee
   -------------------------------------------------------------------------- */
.marquee {
  position: relative;
  padding: clamp(22px, 2.4vw, 40px) 0;
  border-block: 1px solid var(--border-hair);
  overflow: hidden;
}
.marquee__track {
  display: flex;
  width: max-content;
  animation: ad-marquee var(--marquee-duration, 34s) linear infinite;
  transition: animation-duration var(--duration-slow) linear;
}
.marquee:hover .marquee__track { animation-duration: 110s; }
.marquee__group {
  display: flex;
  gap: clamp(28px, 4vw, 72px);
  padding-right: clamp(28px, 4vw, 72px);
  align-items: center;
}
.marquee__item {
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h3);
  letter-spacing: var(--track-snug);
  color: var(--text-heading);
  white-space: nowrap;
}
.marquee__sep { color: var(--amber); font-size: 14px; }

/* --------------------------------------------------------------------------
   16. Team cards
   -------------------------------------------------------------------------- */
.member { display: flex; flex-direction: column; gap: 22px; }
.member--offset { margin-top: clamp(0px, 5vw, 70px); }
.member__media {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: var(--radius-card);
  filter: grayscale(1) contrast(1.04);
  transition: filter 1s var(--ease), transform 1.1s var(--ease);
}
.member__media:hover { filter: grayscale(0) contrast(1); transform: scale(1.02); }
.member__name { margin-bottom: 6px; }
.member__role {
  margin-bottom: 14px;
  font-family: var(--font-ui);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  color: var(--amber);
}
.member__bio { margin-bottom: 16px; max-width: 34ch; }

/* --------------------------------------------------------------------------
   17. Insight cards
   -------------------------------------------------------------------------- */
.insight {
  display: block;
  padding: clamp(24px, 2.6vw, 40px);
  border-radius: var(--radius-card);
  box-shadow: var(--ring-panel);
  transition: box-shadow var(--duration-base) var(--ease), transform var(--duration-base) var(--ease), background var(--duration-base) var(--ease);
}
.insight:hover {
  box-shadow: var(--shadow-card), var(--ring-card);
  transform: translateY(-4px);
  background: var(--surface-card);
}
.insight__title {
  margin: 16px 0 12px;
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h3);
  line-height: var(--lh-h3);
  letter-spacing: var(--track-snug);
  color: var(--text-heading);
}

/* --------------------------------------------------------------------------
   18. Filter pills & tech chips
   -------------------------------------------------------------------------- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filter {
  border-radius: var(--radius-pill);
  padding: 12px 22px;
  box-shadow: var(--ring-nav);
  font-family: var(--font-ui);
  font-weight: var(--weight-medium);
  font-size: var(--size-body-sm);
  color: var(--text-body);
  transition: background var(--duration-base) var(--ease), color var(--duration-base) var(--ease), box-shadow var(--duration-base) var(--ease);
}
.filter:hover { box-shadow: var(--ring-pill); color: var(--text-heading); }
.filter.is-active {
  background: var(--amber);
  color: var(--ink);
  box-shadow: none;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(10px, 1.2vw, 18px);
  justify-content: center;
  max-width: 1100px;
  margin-inline: auto;
}
.chip {
  padding: 14px 28px;
  border-radius: var(--radius-pill);
  box-shadow: var(--ring-nav);
  font-family: var(--font-ui);
  font-weight: var(--weight-medium);
  font-size: var(--size-body);
  color: var(--text-body);
  transition: box-shadow var(--duration-base) var(--ease), color var(--duration-base) var(--ease);
}
.chip:hover { box-shadow: inset 0 0 0 1px var(--amber); color: var(--amber); }
.chip--gold { box-shadow: inset 0 0 0 1px var(--amber); color: var(--amber); }

/* Floating keyword cloud */
.cloud {
  position: relative;
  margin: clamp(40px, 5vw, 80px) auto;
  min-height: clamp(220px, 24vw, 340px);
  display: flex;
  flex-wrap: wrap;
  gap: clamp(12px, 2.2vw, 40px);
  align-items: center;
  justify-content: center;
  max-width: 1080px;
}
.cloud__word {
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h3);
  letter-spacing: var(--track-snug);
  color: var(--text-heading);
}
.cloud__word--dim    { opacity: 0.6; }
.cloud__word--dimmer { opacity: 0.4; }
.cloud__word--gold   { color: var(--amber); }
.cloud__word--lg     { font-size: var(--size-h2); }
.cloud__word--sm     { font-size: var(--size-h4); }

/* --------------------------------------------------------------------------
   19. Forms
   -------------------------------------------------------------------------- */
.form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(12px, 1.4vw, 18px);
  transition: opacity var(--duration-slow) var(--ease), transform var(--duration-slow) var(--ease);
}
@media (max-width: 560px) { .form { grid-template-columns: 1fr; } }

/* Boxed fields — white rounded box, placeholder text, an SVG icon on the right.
   The border lifts to amber on focus. */
.field {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 62px;
  padding: 0 18px;
  background: var(--white);
  border-radius: 14px;
  box-shadow: inset 0 0 0 1px var(--border-hair);
  transition: box-shadow var(--duration-base) var(--ease);
}
.field:focus-within { box-shadow: inset 0 0 0 1.5px var(--amber); }
.field--wide {
  grid-column: 1 / -1;
  align-items: flex-start;
  padding: 16px 18px;
}
.field__input,
.field__select {
  flex: 1;
  min-width: 0;
  width: 100%;
  background: transparent;
  border: 0;
  outline: none;
  padding: 19px 0;
  font-family: var(--font-body);
  font-size: var(--size-body);
  line-height: 1.5;
  color: var(--text-heading);
}
.field__input::placeholder { color: var(--text-muted); opacity: 1; }
.field--wide .field__input {
  padding: 2px 0;
  min-height: 116px;
  resize: vertical;
}
.field__select {
  appearance: none;
  cursor: pointer;
}
.field__select.is-placeholder,
.field__select:has(option[value=""]:checked) { color: var(--text-muted); }
.field__select option { color: var(--ink); }

/* Right-aligned icon */
.field__icon {
  flex: none;
  display: grid;
  place-items: center;
  color: var(--text-muted);
  pointer-events: none;
}
.field__icon svg {
  width: 20px; height: 20px;
  fill: none; stroke: currentColor;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.field:focus-within .field__icon { color: var(--amber); }
.field__icon--top { margin-top: 4px; }

.form__actions { grid-column: 1 / -1; padding-top: 8px; }

.form-done {
  display: none;
  flex-direction: column;
  justify-content: center;
  min-height: 420px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1s var(--ease), transform 1.1s var(--ease);
}
.form-done.is-shown { display: flex; }
.form-done.is-visible { opacity: 1; transform: none; }
.form-done__title {
  margin-top: 20px;
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-display);
  line-height: var(--lh-display);
  letter-spacing: var(--track-tight);
  color: var(--text-heading);
}

.form-alert {
  grid-column: 1 / -1;
  padding: 16px 20px;
  border-radius: var(--radius-field);
  background: rgba(255, 61, 46, 0.06);
  box-shadow: inset 0 0 0 1px var(--red);
  font-family: var(--font-ui);
  font-size: var(--size-body-sm);
  color: var(--red);
}
.form-alert ul { margin: 8px 0 0; padding-left: 18px; }

/* --------------------------------------------------------------------------
   20. Footer
   -------------------------------------------------------------------------- */
.footer {
  position: relative;
  padding: clamp(56px, 6vw, 110px) var(--gutter) 34px;
  background: var(--ink);
  color: var(--white);
  overflow: hidden;
}
.footer--compact { padding: clamp(44px, 4.4vw, 80px) var(--gutter) 32px; }
.footer__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0.22;
  background: url("../img/bg/footer-bg.jpg") 50% 50% / cover no-repeat;
  pointer-events: none;
}
.footer > *:not(.footer__bg) { position: relative; z-index: 1; }
.footer__hairline {
  position: absolute;
  top: 0; left: 0;
  height: 1px;
  width: 0;
  background: linear-gradient(90deg, transparent, var(--amber), transparent);
  transition: width 2.2s var(--ease);
  z-index: 2;
}
.footer__grid {
  max-width: var(--shell);
  margin-inline: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: clamp(28px, 3vw, 60px);
  align-items: start;
}
.footer__blurb { margin-top: 18px; color: var(--gray-c5); }
.footer__col-title {
  font-family: var(--font-ui);
  font-weight: var(--weight-semibold);
  font-size: var(--size-body-sm);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--amber);
  margin-bottom: 6px;
}
.footer__link { font-size: var(--size-body-sm); color: var(--gray-c5); }
.footer__link:hover { color: var(--amber); }
.footer__place {
  margin-top: 18px;
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h4);
  line-height: 1.4;
  color: var(--white);
}
.footer__legal {
  max-width: var(--shell);
  margin: clamp(36px, 4vw, 64px) auto 0;
  padding-top: 22px;
  border-top: 1px solid var(--ink-31);
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
  font-family: var(--font-ui);
  font-size: var(--size-body-sm);
  color: var(--gray-66);
}
.footer__bar {
  max-width: var(--shell);
  margin-inline: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: space-between;
  align-items: center;
}
.footer__tagline {
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: var(--size-h4);
  color: var(--gray-c5);
}
.footer__copy { font-family: var(--font-ui); font-size: var(--size-body-sm); color: var(--gray-66); }
.footer--ruled { border-top: 1px solid var(--ink-31); }

/* --------------------------------------------------------------------------
   21. Closing CTA
   -------------------------------------------------------------------------- */
.cta__title {
  margin: clamp(20px, 2.2vw, 34px) 0 clamp(28px, 3vw, 48px);
  font-size: var(--size-mega);
  line-height: var(--lh-mega);
  letter-spacing: var(--track-tight);
}
.cta__lede {
  margin: 0 auto clamp(28px, 3vw, 48px);
  max-width: 52ch;
}

/* ==========================================================================
   Carried over from the original site, re-skinned with the Averix tokens
   (ink #0f0f0f, amber #ecb014, cards #1e1e1e):
     · the closing CTA card
     · the card footer — sliding wordmark, business card, contact + status
       cards, big-nav letter-roll, ecosystem, back-to-top.
   ========================================================================== */

/* -- Closing CTA card ----------------------------------------------------- */
.cta-band {
  position: relative; overflow: hidden;
  margin-inline: auto; width: 100%; max-width: var(--shell);
  background: var(--off-f5); color: var(--ink);
  border-radius: 30px;
  padding: clamp(56px, 7.5vw, 120px) clamp(28px, 5vw, 90px);
}
.cta-band__content {
  position: relative; z-index: 1; max-width: 62%;
  display: flex; flex-direction: column; align-items: flex-start;
  gap: clamp(26px, 3.4vw, 48px);
}
.cta-band h2 {
  margin: 0; font-family: var(--font-display);
  font-size: clamp(34px, 5.2vw, 76px); font-weight: var(--weight-bold);
  letter-spacing: -0.045em; line-height: 1.02; color: var(--ink);
}
.cta-band h2 em { font-style: italic; color: var(--ink-pure); }
.cta-band p {
  margin: 0; max-width: 46ch; color: var(--ink-a75);
  font-family: var(--font-body); font-size: clamp(16px, 1.3vw, 19px); line-height: 1.55;
}
.cta-band__spark {
  display: inline-block; vertical-align: baseline;
  width: clamp(24px, 2.6vw, 44px); height: clamp(24px, 2.6vw, 44px);
  margin-right: .32em; color: var(--ink-pure);
}
.cta-band__spark svg { width: 100%; height: 100%; display: block; }
.cta-band__art {
  position: absolute; right: -5%; top: 50%; transform: translateY(-50%);
  width: min(46%, 520px); aspect-ratio: 1; pointer-events: none;
}
.cta-band__art svg { width: 100%; height: 100%; display: block; overflow: visible; }
.cta-art__ring  { transform-origin: 210px 210px; animation: ctaSpin 46s linear infinite; }
.cta-art__ring--2 { animation: ctaSpin 30s linear infinite reverse; }
.cta-art__spark { transform-origin: center; animation: ctaPulse 3.4s ease-in-out infinite; }
.cta-art__spark--b { animation-duration: 4.6s; animation-delay: -1.2s; }
@keyframes ctaSpin  { to { transform: rotate(360deg); } }
@keyframes ctaPulse { 0%,100% { transform: scale(1); opacity: .9; } 50% { transform: scale(1.16); opacity: .55; } }

/* The large pill button inside the CTA card. */
.cta-btn {
  display: inline-flex; align-items: center; gap: 14px;
  min-height: clamp(62px, 6vw, 84px); padding: 0 clamp(26px, 2.4vw, 38px);
  border-radius: 100px; text-decoration: none;
  font-family: var(--font-display); font-size: clamp(17px, 1.7vw, 24px);
  font-weight: var(--weight-semibold); letter-spacing: -0.02em;
  background: var(--ink); color: var(--white);
  transition: background .25s, color .25s;
}
.cta-btn:hover { background: var(--amber); color: var(--ink); }
.cta-btn__arrow {
  display: grid; place-items: center; flex: none;
  width: clamp(30px, 2.6vw, 40px); height: clamp(30px, 2.6vw, 40px);
  border-radius: 50%; background: currentColor;
  transition: transform .25s cubic-bezier(.6,0,.2,1);
}
.cta-btn__arrow svg { width: 44%; height: 44%; stroke: var(--amber); fill: none; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.cta-btn:hover .cta-btn__arrow { transform: translate(3px,-3px) rotate(45deg); }

/* -- Sliding wordmark ----------------------------------------------------- */
.wordmark { padding: 60px 0 10px; overflow: hidden; }
/* Ink glyph on the white page (the JS slides + fades it up on scroll). Painted
   via background-clip:text so the fill is transparent — the reveal is pure
   decoration, so contrast audits skip this node. */
.wordmark__text {
  font-family: var(--font-brand); font-weight: 800;
  font-size: 13.2vw; line-height: .86; letter-spacing: -0.05em;
  text-align: center; white-space: nowrap;
  color: transparent; background: var(--ink);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}

/* -- Footer cards --------------------------------------------------------- */
.site-footer-cards {
  display: grid; grid-template-columns: 1.15fr 1fr 1.05fr; gap: 14px;
  margin: 40px auto 24px; width: min(100% - 2 * clamp(16px, 4vw, 40px), var(--shell));
}
.fcard { background: var(--ink-1e); border: none; border-radius: 24px; padding: 40px; display: flex; flex-direction: column; gap: 12px; }
.fcard--nav, .fcard--eco { justify-content: space-between; min-height: 580px; }
.footer-mid { display: flex; flex-direction: column; gap: 14px; }
.fcard--fill { flex: 1; min-height: 300px; }

/* Business card — amber, ink type, laid out like a physical card. */
.bizcard { background: var(--amber); color: var(--ink); justify-content: space-between; padding: 34px; position: relative; overflow: hidden; }
.bizcard::after { content: ""; position: absolute; right: -60px; bottom: -60px; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(0,0,0,.10), transparent 70%); pointer-events: none; }
.bizcard__top { display: flex; align-items: center; gap: 11px; position: relative; z-index: 1; }
.bizcard__logo { display: block; width: 34px; height: 34px; color: var(--ink); }
.bizcard__logo svg { display: block; width: 100%; height: 100%; }
.bizcard__logo rect:last-child { fill: var(--ink); opacity: .45; } /* amber top layer disappears on the amber card */
.bizcard__brandwrap { display: grid; gap: 3px; }
.bizcard__brand { font-family: var(--font-brand); font-size: 20px; font-weight: 600; letter-spacing: -.045em; line-height: 1; }
.bizcard__tag { font-family: var(--font-ui); font-size: 8px; font-weight: 600; letter-spacing: .32em; text-transform: uppercase; line-height: 1; color: rgba(15,15,15,.6); }
.bizcard__body { position: relative; z-index: 1; }
.bizcard__name { margin: 0; font-family: var(--font-display); font-size: clamp(26px, 2.4vw, 34px); font-weight: var(--weight-semibold); letter-spacing: -.03em; line-height: 1.05; }
.bizcard__role { margin: 6px 0 0; font-size: 13px; font-weight: 600; letter-spacing: .04em; color: rgba(15,15,15,.62); }
.bizcard__foot { display: flex; flex-direction: column; gap: 5px; position: relative; z-index: 1; border-top: 1px solid rgba(15,15,15,.2); padding-top: 16px; font-size: 14px; }
.bizcard__foot a { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); font-weight: 600; width: fit-content; text-decoration: none; }
.bizcard__foot a:hover .bizcard__ico { opacity: 1; }
.bizcard__ico { width: 15px; height: 15px; flex: none; opacity: .7; }
.bizcard__foot span { color: rgba(15,15,15,.55); font-size: 12.5px; letter-spacing: .04em; }

/* Big-nav — Rayo-style letter roll on hover (structure built by footer.php's inline JS). */
.footer-bignav a { font-family: var(--font-display); font-size: clamp(30px, 2.6vw, 42px); font-weight: var(--weight-semibold); color: var(--white); letter-spacing: -0.025em; display: block; padding: 8px 0; line-height: 1.1; text-decoration: none; }
.footer-bignav .count { display: inline-flex; align-items: center; gap: 4px; background: var(--amber); color: var(--ink); border-radius: 100px; padding: 5px 13px; font-size: 14px; font-weight: 600; font-family: var(--font-body); letter-spacing: 0; vertical-align: middle; margin-left: 12px; transform: translateY(-6px); }
.footer-bignav .roll { display: inline-block; position: relative; overflow: hidden; vertical-align: top; line-height: 1.1; }
.footer-bignav .roll__block { display: block; white-space: nowrap; }
.footer-bignav .roll__block--dup { position: absolute; top: 100%; left: 0; color: var(--amber); }
.footer-bignav .roll__l { display: inline-block; transition: transform .55s cubic-bezier(.76,0,.024,1); }
.footer-bignav a:hover .roll__l { transform: translateY(-100%); }

/* Contact — a big, card-filling CTA. */
.fcard--contact { flex-direction: row; align-items: center; justify-content: space-between; gap: 18px; text-decoration: none; transition: background .2s; }
.fcard--contact:hover { background: var(--ink-18); }
.fcard-contact__t { font-family: var(--font-display); font-weight: var(--weight-semibold); font-size: clamp(34px, 3vw, 50px); letter-spacing: -.03em; line-height: 1; color: var(--white); }
.fcard-contact__i { flex: none; display: grid; place-items: center; width: 54px; height: 54px; border-radius: 50%; border: 1px solid var(--white-a20); color: var(--white); transition: transform .3s cubic-bezier(.2,.7,.2,1), background .25s, border-color .25s, color .25s; }
.fcard-contact__i svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fcard--contact:hover .fcard-contact__i { background: var(--amber); border-color: var(--amber); color: var(--ink); transform: translate(4px,-4px); }

/* Availability. */
.fcard--status { justify-content: center; gap: 12px; }
.fcard-status__t { margin: 0; display: flex; align-items: center; gap: 14px; font-family: var(--font-display); font-size: 19px; font-weight: var(--weight-semibold); color: var(--white); }
.fcard-status__s { margin: 0; padding-left: 25px; font-size: 14px; color: var(--white-a50); }
.status-dot { flex: none; position: relative; width: 11px; height: 11px; border-radius: 50%; background: #31d07f; }
.status-dot::before { content: ""; position: absolute; inset: 0; border-radius: 50%; background: #31d07f; animation: statusPulse 2.4s ease-out infinite; }
@keyframes statusPulse { 0% { transform: scale(1); opacity: .7; } 70%,100% { transform: scale(2.8); opacity: 0; } }

/* Ecosystem. */
.fcard-title { margin: 0; font-size: 14px; font-weight: 600; color: var(--white); }
.fcard-title--l { font-family: var(--font-display); font-size: 34px; letter-spacing: -0.025em; margin-bottom: 18px; }
.fcard-sub { margin: 0; font-size: 13px; color: var(--gray-c5); }
.eco-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.eco-list a { color: var(--gray-c5); font-size: 16px; text-decoration: none; }
.eco-list a:hover { color: var(--white); }

/* Back to top. */
.to-top {
  position: fixed; right: clamp(16px, 3vw, 32px); bottom: clamp(16px, 3vw, 32px); z-index: 70;
  width: clamp(44px, 4vw, 54px); height: clamp(44px, 4vw, 54px);
  display: grid; place-items: center; border-radius: 50%;
  background: var(--ink-1e); border: 1px solid var(--white-a20); color: var(--white); cursor: pointer;
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity .3s, visibility .3s, transform .3s, background .25s, border-color .25s, color .25s;
}
.to-top.is-shown { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--amber); border-color: var(--white); color: var(--ink); }
.to-top svg { width: 22px; height: 22px; }
.to-top:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  .cta-art__ring, .cta-art__spark, .status-dot::before { animation: none; }
}

/* Responsive. */
@media (max-width: 1000px) {
  .site-footer-cards { grid-template-columns: 1fr 1fr; }
  .fcard--eco { grid-column: 1 / -1; min-height: auto; }
  .cta-band { display: flex; flex-direction: column; }
  .cta-band__content { max-width: 100%; }
  .cta-band__art { position: static; transform: none; width: min(300px, 72%); margin: 38px auto 0; }
}
@media (max-width: 680px) {
  .site-footer-cards { grid-template-columns: 1fr; }
  .fcard--nav { min-height: auto; }
  .fcard { padding: 30px; }
  .fcard--fill { min-height: 240px; }
}

/* ==========================================================================
   Home — Clients testimonials carousel (rating card + scrolling quote cards)
   ========================================================================== */
.treview-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: clamp(32px, 4vw, 56px);
}
.treview-title { margin-top: var(--eyebrow-gap); }
.treview-nav { display: flex; gap: 12px; flex: none; }
.tnav-btn {
  width: clamp(46px, 3.6vw, 56px);
  height: clamp(46px, 3.6vw, 56px);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: transparent;
  color: var(--text-heading);
  box-shadow: inset 0 0 0 1px var(--border-hair);
  cursor: pointer;
  transition: background var(--duration-fast) var(--ease), color var(--duration-fast) var(--ease), box-shadow var(--duration-fast) var(--ease);
}
.tnav-btn svg { width: 22px; height: 22px; }
.tnav-btn:hover { background: var(--action-fill); color: var(--action-text); box-shadow: none; }

.tcarousel {
  display: flex;
  gap: clamp(16px, 1.6vw, 24px);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 6px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.tcarousel::-webkit-scrollbar { display: none; }

.tcard {
  flex: 0 0 clamp(290px, 34vw, 500px);
  scroll-snap-align: start;
  background: var(--white);
  border-radius: var(--radius-card);
  box-shadow: var(--ring-card);
  padding: clamp(24px, 2.4vw, 36px);
  display: flex;
  gap: clamp(16px, 1.8vw, 28px);
}

/* Rating card — dark */
.tcard--rating {
  flex-basis: clamp(260px, 26vw, 360px);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: clamp(14px, 1.6vw, 22px);
  background: var(--ink);
  color: var(--white);
}
.trating__score {
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  font-size: clamp(60px, 7vw, 104px);
  line-height: 1;
  color: var(--white);
}
.trating__meta {
  font-family: var(--font-ui);
  font-size: var(--size-body-sm);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--white-a50);
}
.trating__pitch {
  margin: clamp(6px, 1vw, 14px) 0 0;
  font-family: var(--font-body);
  font-size: var(--size-body);
  line-height: 1.6;
  color: var(--gray-c5);
  max-width: 26ch;
}

/* Star rating */
.tstars { color: var(--amber); letter-spacing: 3px; font-size: 15px; line-height: 1; }
.tstars--lg { font-size: 22px; }

/* Testimonial card */
/* Vertical label: title with the subtitle stacked directly under it, then the
   whole block rotated as one unit so it reads bottom-to-top up the card edge. */
.tcard__aside {
  flex: 0 0 clamp(46px, 4.4vw, 62px);
  align-self: stretch;
  position: relative;
}
.tcard__rot {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-90deg);
  transform-origin: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  white-space: nowrap;
  text-align: center;
}
.tcard__name {
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  font-size: clamp(14px, 1.1vw, 18px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--text-heading);
}
.tcard__role {
  font-family: var(--font-ui);
  font-size: 11.5px;
  letter-spacing: 0.02em;
  color: var(--text-muted);
}
.tcard__body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(12px, 1.3vw, 18px);
  border-left: 1px solid var(--border-hair);
  padding-left: clamp(18px, 2vw, 32px);
}
.tcard__mark {
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  font-size: 56px;
  line-height: 0.5;
  height: 26px;
  color: var(--ink);
}
.tcard__quote {
  margin: 0;
  font-family: var(--font-body);
  font-size: clamp(15px, 1.15vw, 18px);
  line-height: 1.55;
  color: var(--text-body);
}
.tcard__body .tstars { margin-top: 2px; }

@media (max-width: 620px) {
  .tcard { flex-basis: 86%; padding: 26px; gap: 18px; }
  .tcard--rating { flex-basis: 78%; }
  .tcard__mark { font-size: 56px; }
}

/* --------------------------------------------------------------------------
   Mobile / tablet nav — give the brand lockup its own white capsule (matching
   the burger capsule) with the "AppanDesign" wordmark on it. Two pills: the
   logo on the left, the menu burger on the right.
   -------------------------------------------------------------------------- */
@media (max-width: 1079px) {
  .nav .brand,
  .nav--over-dark .brand,
  .nav--on-dark .brand {
    height: var(--nav-h);
    padding: 0 22px 0 16px;
    gap: 10px;
    border-radius: var(--radius-nav);
    /* Frosted glass, matching the burger capsule. */
    background: rgba(255, 255, 255, 0.62);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
    color: var(--ink);                 /* ink on the pill, even over the dark hero */
    box-shadow: var(--ring-nav), var(--shadow-nav);
  }
  .nav .brand__name { display: inline; }   /* keep the wordmark on the pill at all sizes */
  @supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .nav .brand,
    .nav--over-dark .brand,
    .nav--on-dark .brand { background: rgba(255, 255, 255, 0.92); }
  }
}
@media (max-width: 700px) {
  .nav .brand,
  .nav--over-dark .brand,
  .nav--on-dark .brand { height: 64px; padding: 0 20px 0 14px; gap: 11px; }
  /* Bigger lockup on phones — the pill has the room. */
  .nav .brand__mark { height: 36px; }
  .nav .brand__name { font-size: 23px; }
  .nav .brand__tag  { font-size: 8.5px; }
}

/* --------------------------------------------------------------------------
   Mobile hero — drop the floating 3D iso-cube + amber decor (busy on a phone)
   and move the text up to the top instead of pinning it to the bottom.
   -------------------------------------------------------------------------- */
@media (max-width: 760px) {
  .section--hero {
    /* Hug the content rather than forcing a full-screen height — a forced
       100svh left a big empty void under the buttons on tall phones. */
    min-height: auto;
    align-items: flex-start;
    padding-top: calc(clamp(132px, 32vw, 168px) + env(safe-area-inset-top, 0px));
    padding-bottom: clamp(56px, 12vw, 88px);
  }
  .section--hero .iso,
  .section--hero .deco-rule,
  .section--hero .deco-diamond,
  .section--hero .scroll-cue { display: none; }
  .hero__foot { flex-direction: column; align-items: stretch; gap: clamp(20px, 6vw, 32px); }
  /* Buttons side by side, sharing the row. */
  .hero__actions { flex-wrap: nowrap; gap: 10px; }
  .hero__actions .btn {
    flex: 1 1 0;
    min-width: 0;
    padding: 12px 12px 12px 16px;
    font-size: clamp(12px, 3.3vw, 15px);
  }
  /* Don't let the min-height frames force extra cropping on a narrow card. */
  .frame--16x9, .frame--21x9, .frame--4x5 { min-height: 0; }
}

/* White breathing room under the footer cards on phones, so the translucent
   iOS/Android browser bar sits over white — not the dark footer card — when
   you're scrolled to the bottom. Tall enough to clear the bar + home indicator
   (safe-area inset), which is why 24px wasn't enough. */
@media (max-width: 760px) {
  .site-footer-cards {
    margin-bottom: calc(clamp(96px, 28vw, 150px) + env(safe-area-inset-bottom, 0px));
  }
}

/* --------------------------------------------------------------------------
   Mobile nav over a dark band — DARK glass pills.
   iOS Safari tints its status bar from the elements sitting just under it; two
   white glass pills there force the bar white over the dark hero. Dark pills
   over the hero make Safari tint the bar dark (hero reads edge-to-edge), and
   they revert to white glass over the light sections. motion.js keeps
   `nav--on-dark` in sync while scrolling.
   -------------------------------------------------------------------------- */
@media (max-width: 1079px) {
  .nav__capsule,
  .nav .brand { transition: background var(--duration-base) var(--ease), color var(--duration-base) var(--ease), box-shadow var(--duration-base) var(--ease); }

  .nav--over-dark .nav__capsule,
  .nav--on-dark .nav__capsule,
  .nav--over-dark .brand,
  .nav--on-dark .brand {
    background: rgba(15, 15, 15, 0.62);
    color: var(--white);
    box-shadow: inset 0 0 0 1px var(--white-a20), var(--shadow-nav);
  }
  .nav--over-dark .burger__bar,
  .nav--on-dark .burger__bar { background: var(--white); }
}

/* ==========================================================================
   Closing CTA — "stacked deck". Dark card, copy left, three receding 3D cards
   on the right that fan out on hover. Shared by every page via partials/cta.php.
   ========================================================================== */
/* Full-bleed band: the section carries the ink surface, the .shell inside
   keeps the copy and deck on the page grid. */
.cta-deck-sec {
  overflow: hidden;
  padding-block: clamp(56px, 7vw, 120px);
  background: var(--ink);
}
.cta-deck {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(28px, 4vw, 56px);
}
.cta-deck__title {
  margin: 14px 0 16px;
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  font-size: clamp(34px, 5vw, 70px);
  line-height: 1.02;
  letter-spacing: -0.04em;
  color: var(--white);
}
.cta-deck__title em { font-style: normal; color: var(--amber); }
.cta-deck__lede {
  margin: 0 0 30px;
  max-width: 44ch;
  font-family: var(--font-body);
  font-size: clamp(15px, 1.2vw, 18px);
  line-height: 1.6;
  color: var(--gray-c5);
}
.cta-deck__actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* The 3D deck */
.cta-deck__stage { perspective: 1200px; display: grid; place-items: center; min-height: 340px; }
.cta-deck__deck {
  position: relative;
  width: min(300px, 62vw);
  aspect-ratio: 4 / 3;
  transform-style: preserve-3d;
  transform: rotateX(56deg) rotateZ(-32deg);
  transition: transform 0.8s var(--ease);
  animation: ctaDeckBob 6s ease-in-out infinite;
}
.cta-deck__stage:hover .cta-deck__deck { transform: rotateX(48deg) rotateZ(-26deg); }
.cta-deck__layer {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: 18px;
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  font-size: 30px;
  letter-spacing: -0.03em;
  background: var(--white);
  color: var(--ink);
  box-shadow: 0 30px 40px -18px rgba(0, 0, 0, 0.9), inset 0 0 0 1px rgba(15, 15, 15, 0.1);
  transition: transform 0.8s var(--ease);
}
.cta-deck__layer--1 {
  transform: translateZ(0);
  background: var(--ink-1e);
  color: var(--white);
  box-shadow: 0 30px 40px -18px rgba(0, 0, 0, 0.9), inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}
.cta-deck__layer--2 { transform: translateZ(50px); background: var(--amber); }
.cta-deck__layer--3 { transform: translateZ(100px); }
.cta-deck__stage:hover .cta-deck__layer--2 { transform: translateZ(110px); }
.cta-deck__stage:hover .cta-deck__layer--3 { transform: translateZ(220px); }
.cta-deck__mark { display: block; width: 44%; color: var(--ink); }
.cta-deck__mark svg { width: 100%; height: auto; display: block; }
@keyframes ctaDeckBob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -12px; } }

@media (max-width: 860px) {
  /* Stack order on phones: copy → 3D deck → buttons. The copy wrapper
     dissolves so its children sit on the same grid as the stage. */
  .cta-deck { grid-template-columns: 1fr; }
  .cta-deck__copy { display: contents; }
  .cta-deck__stage { order: 1; min-height: 280px; }
  .cta-deck__actions { order: 2; flex-wrap: nowrap; gap: 10px; }
  .cta-deck__actions .btn {
    flex: 1 1 0;
    min-width: 0;
    padding: 12px 12px 12px 16px;
    font-size: clamp(12px, 3.3vw, 15px);
  }
  .cta-deck__lede { margin-bottom: 0; }
  .cta-deck__deck { width: min(220px, 58vw); }      /* smaller stack on phones */
  .cta-deck__stage { min-height: 240px; }
}
@media (prefers-reduced-motion: reduce) {
  .cta-deck__deck { animation: none; }
}
