/* ══════════════════════════════════════
   ECHO — agency.css
   About us page (about.html): hero with film, service links, story,
   clients, how we work (the landscape). Fade-ins use the same values as the homepage
   (16px, 0.7s, the site ease, 90ms stagger); reduced-motion visitors
   get the finished state.
   ══════════════════════════════════════ */

/* ── Shared ── */
/* same fade as the homepage's .reveal-fade (index.css) */
.ag-js .reveal-fade {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: calc(var(--i, 0) * 90ms);
}
.ag-js .reveal-fade.visible { opacity: 1; transform: none; }

/* ── 1. Hero ── */
.ag-hero__inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  padding-bottom: clamp(4rem, 8vw, 7rem);
}
.ag-hero__headline {
  margin: 0 0 1.35rem;
  font-family: var(--font-head);
  font-size: clamp(2.9rem, 5.6vw, 5.4rem);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: 0;
  color: #f6f1ff;
}
.ag-hero__headline em {
  display: block;
  margin-top: 0.15em;
  font-style: italic;
  font-weight: 400;
  color: #c9b7ff;
}
.ag-hero__headline .h1-label { display: block; }

/* "See our work": a text link next to the main button */
@media (min-width: 701px) {
  .ag-hero .about-actions { align-items: center; }
}
.ag-text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 0.25rem;
  font-weight: 500;
  color: #c9b7ff;
  text-decoration: underline;
  text-decoration-color: rgba(201, 183, 255, 0.4);
  text-underline-offset: 5px;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}
.ag-text-link:hover { color: #f6f1ff; text-decoration-color: currentColor; }
.ag-text-link:focus-visible { outline: 2px solid #c9b7ff; outline-offset: 3px; border-radius: 4px; }

/* film card */
.ag-film {
  position: relative;
  margin: 0;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  background: radial-gradient(circle at 50% 50%, rgba(123, 87, 255, 0.35), transparent 60%), #1e1040;
  border: 1px solid rgba(201, 183, 255, 0.22);
  box-shadow: 0 30px 80px rgba(8, 2, 28, 0.45);
}
.ag-film__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #14092f;
}

/* controls: always visible, bottom-right, big enough to tap */
.ag-film__controls {
  position: absolute;
  right: 0.75rem;
  bottom: 0.75rem;
  z-index: 2;
  display: flex;
  gap: 0.5rem;
}
.ag-film__btn {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(246, 241, 255, 0.35);
  border-radius: 50%;
  background: rgba(20, 9, 47, 0.62);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
  color: #f6f1ff;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.ag-film__btn:hover { background: rgba(91, 43, 224, 0.85); border-color: rgba(246, 241, 255, 0.6); }
.ag-film__btn:active { transform: scale(0.94); }
.ag-film__btn:focus-visible { outline: 2px solid #c9b7ff; outline-offset: 3px; }
.ag-film__btn svg { width: 20px; height: 20px; }

/* icon states */
.ag-ico-play, .ag-ico-sound, .ag-ico-shrink { display: none; }
.ag-film.is-paused .ag-ico-pause { display: none; }
.ag-film.is-paused .ag-ico-play { display: block; }
.ag-film.has-sound .ag-ico-muted { display: none; }
.ag-film.has-sound .ag-ico-sound { display: block; }
.ag-film.is-full .ag-ico-expand { display: none; }
.ag-film.is-full .ag-ico-shrink { display: block; }

/* full screen: whole film visible, no card styling */
.ag-film:fullscreen { border: 0; border-radius: 0; box-shadow: none; background: #000; }
.ag-film:fullscreen .ag-film__video { object-fit: contain; background: #000; }
.ag-film:fullscreen .ag-film__controls { right: 1.5rem; bottom: 1.5rem; }
.ag-film:-webkit-full-screen { border: 0; border-radius: 0; box-shadow: none; background: #000; }
.ag-film:-webkit-full-screen .ag-film__video { object-fit: contain; background: #000; }

/* ── What we do: one line of service links under the hero ── */
.ag-strip {
  padding: 1.35rem 0;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.ag-strip__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 1.5rem;
}
.ag-strip__label {
  font-family: 'DM Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--accent);
}
.ag-strip__list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ag-strip__list li + li::before { content: "·"; margin: 0 0.8rem; color: var(--accent); }
.ag-strip__list a {
  font-size: 0.95rem;
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 4px;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}
.ag-strip__list a:hover { color: var(--accent); text-decoration-color: currentColor; }

/* ── 2. Story ── */
.ag-story { background: var(--bg); }
.ag-story__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}
.ag-story__copy p { margin: 0 0 1.1rem; line-height: 1.75; color: var(--text-muted); }
.ag-story__copy p:first-child { font-size: clamp(1.05rem, 1.45vw, 1.2rem); color: var(--text); }
.ag-story__copy .ag-story__sign {
  margin: 1.6rem 0 0;
  font-family: 'DM Mono', monospace;
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

/* ── 3. Clients ── */
.ag-clients { background: var(--surface); }
.ag-clients__grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
}
.ag-client {
  padding: 1.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
}
.ag-client__logo {
  display: block;
  height: calc(var(--h, 2rem) * 1.1);
  aspect-ratio: var(--ar, 4);
  max-width: 100%;
  margin-bottom: 1.1rem;
  background-color: var(--text);
  -webkit-mask-repeat: no-repeat;
          mask-repeat: no-repeat;
  -webkit-mask-size: contain;
          mask-size: contain;
  -webkit-mask-position: left center;
          mask-position: left center;
}
.ag-client p { margin: 0; line-height: 1.65; color: var(--text-muted); }
.ag-client b { color: var(--text); font-weight: 600; }

/* ── 4. How we work: a landscape seen from the side ──
   agency.js draws the terrain and moves through it as the visitor scrolls
   (.is-live). Without that (reduced motion, very short screens, no JS) the
   steps show as a list under a still picture of the whole route (.is-static). */
.ag-journey { position: relative; color: #f6f1ff; background: #150a31; }
.ag-journey__stage {
  position: relative;
  overflow: hidden;
  padding: clamp(5rem, 10vw, 8rem) 0 clamp(4rem, 8vw, 6rem);
  background:
    radial-gradient(ellipse 55% 45% at 80% 16%, rgba(123, 87, 255, 0.26), transparent 70%),
    linear-gradient(180deg, #110726 0%, #1a0c3d 50%, #27145c 100%);
}
.ag-journey__sky {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image:
    radial-gradient(1px 1px at 12% 22%, #fff, transparent),
    radial-gradient(1px 1px at 27% 9%, rgba(255, 255, 255, 0.8), transparent),
    radial-gradient(1.5px 1.5px at 41% 31%, rgba(255, 255, 255, 0.7), transparent),
    radial-gradient(1px 1px at 58% 13%, #fff, transparent),
    radial-gradient(1px 1px at 69% 35%, rgba(255, 255, 255, 0.6), transparent),
    radial-gradient(1.5px 1.5px at 84% 8%, rgba(255, 255, 255, 0.8), transparent),
    radial-gradient(1px 1px at 93% 27%, #fff, transparent),
    radial-gradient(1px 1px at 5% 41%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(1px 1px at 35% 44%, rgba(255, 255, 255, 0.4), transparent),
    radial-gradient(1px 1px at 76% 46%, rgba(255, 255, 255, 0.4), transparent);
}
.ag-journey__head {
  position: relative;
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 2rem;
}
.ag-journey .section-label { color: #c9b7ff; }
.ag-journey__title { margin: 0; color: #f6f1ff; font-size: clamp(2.1rem, 3.4vw, 3rem); }

/* step buttons: jump to any stop; the line fills as you travel */
.ag-journey__nav { display: none; }
.ag-journey.is-live .ag-journey__nav { position: relative; display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.35rem; }
.ag-journey__track { position: absolute; left: 17px; right: 17px; top: 50%; height: 1px; background: rgba(201, 183, 255, 0.25); }
.ag-journey__fill { position: absolute; inset: 0; background: #c9b7ff; transform-origin: left center; transform: scaleX(0); }
.ag-journey__dot {
  position: relative;
  z-index: 1;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid rgba(201, 183, 255, 0.35);
  border-radius: 50%;
  background: #160b33;
  color: rgba(246, 241, 255, 0.7);
  font: 500 0.68rem/1 'DM Mono', monospace;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}
.ag-journey__dot:hover { border-color: #c9b7ff; color: #fff; }
.ag-journey__dot.is-active { background: #5b2be0; border-color: #a58bff; color: #fff; }
.ag-journey__dot:focus-visible { outline: 2px solid #c9b7ff; outline-offset: 3px; }

/* the steps */
.ag-journey__view { position: relative; z-index: 2; margin-top: 2.5rem; }
.ag-land { display: block; width: 100%; height: auto; }
.ag-journey__steps { list-style: none; margin: 0; padding: 0; }
.ag-jstep__num {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font: 500 0.74rem/1 'DM Mono', monospace;
  letter-spacing: 0.14em;
  color: #c9b7ff;
}
.ag-jstep__num::after { content: ""; width: 2.25rem; height: 1px; background: rgba(201, 183, 255, 0.45); }
.ag-jstep h3 {
  margin: 0.8rem 0 0.6rem;
  font-family: var(--font-head);
  font-size: clamp(1.75rem, 2.5vw, 2.45rem);
  font-weight: 600;
  line-height: 1.08;
  color: #f6f1ff;
}
.ag-jstep p { margin: 0; max-width: 42ch; line-height: 1.7; color: rgba(246, 241, 255, 0.76); }

/* live: the stage stays on screen while the visitor scrolls through the track */
.ag-journey.is-live { height: calc(100vh + 400vh); height: calc(100svh + 400svh); }
.ag-journey.is-live .ag-journey__stage { position: sticky; top: 0; height: 100vh; height: 100svh; padding: 0; }
.ag-journey.is-live .ag-journey__head { position: absolute; top: clamp(5.5rem, 12vh, 7rem); left: 0; right: 0; }
.ag-journey.is-live .ag-journey__view { position: absolute; inset: 0; margin: 0; }
.ag-journey.is-live .ag-land { position: absolute; left: 0; top: 0; width: auto; height: auto; }
.ag-journey.is-live .ag-journey__steps { position: absolute; left: 0; top: 0; width: 100%; height: 100%; will-change: transform; pointer-events: none; }
.ag-journey.is-live .ag-jstep { position: absolute; opacity: 0; text-shadow: 0 2px 18px rgba(17, 7, 38, 0.65); }

/* static: the whole route as one picture, the steps as a list */
.ag-journey.is-static .ag-journey__steps,
.ag-journey:not(.is-live) .ag-journey__steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 2rem;
  max-width: var(--max-w);
  margin: 2.5rem auto 0;
  padding: 0 clamp(1.25rem, 5vw, 3rem);
}
.ag-journey:not(.is-live) .ag-jstep h3 { font-size: clamp(1.4rem, 2vw, 1.75rem); }

/* the drawing (agency.js builds it) */
.ag-ridge--far { fill: rgba(160, 130, 255, 0.07); }
.ag-ridge--mid { fill: rgba(160, 130, 255, 0.11); }
.ag-stratum { fill: none; stroke: rgba(201, 183, 255, 0.13); stroke-width: 1; }
.ag-surface { fill: none; stroke: rgba(201, 183, 255, 0.55); stroke-width: 1.5; stroke-linejoin: round; }
.ag-route-ahead { fill: none; stroke: rgba(233, 224, 255, 0.45); stroke-width: 2; stroke-linecap: round; stroke-dasharray: 1 8; }
.ag-route-glow { fill: none; stroke: rgba(155, 109, 255, 0.38); stroke-width: 9; stroke-linecap: round; stroke-linejoin: round; }
.ag-route-core { fill: none; stroke: #efe8ff; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.ag-route-pulse { fill: none; stroke: #fff; stroke-width: 3; stroke-linecap: round; opacity: 0; transition: opacity 0.5s ease; }
.ag-pin__pole { stroke: rgba(233, 224, 255, 0.8); stroke-width: 1.5; }
.ag-pin__head { fill: #c9b7ff; }
.ag-pulse { fill: none; stroke: #c9b7ff; stroke-width: 1.5; opacity: 0; transform-box: fill-box; transform-origin: center; }
.ag-journey.is-near .ag-pulse { animation: agJPulse 2.8s ease-out infinite; }
.ag-journey.is-near .ag-pulse--late { animation-delay: 1.4s; }
@keyframes agJPulse { 0% { transform: scale(0.6); opacity: 0.9; } 100% { transform: scale(3.2); opacity: 0; } }
.ag-label { opacity: 0; }
.ag-label text { font: 500 10.5px 'DM Mono', monospace; letter-spacing: 0.14em; fill: rgba(233, 224, 255, 0.88); }
.ag-label circle { fill: #c9b7ff; }
.ag-scan { opacity: 0; }
.ag-scan__line { stroke: #ddd2ff; stroke-width: 1.5; }
.ag-echo path { fill: none; stroke: rgba(201, 183, 255, 0.7); stroke-width: 1.5; opacity: 0; transform-box: fill-box; transform-origin: 50% 100%; }
.ag-journey.is-near .ag-echo path { animation: agJEcho 3s ease-out infinite; }
@keyframes agJEcho { 0% { transform: scale(0.25); opacity: 0; } 15% { opacity: 0.9; } 100% { transform: scale(1.25); opacity: 0; } }
.ag-branch { opacity: 0; }
.ag-branch path { fill: none; stroke: rgba(233, 224, 255, 0.6); stroke-width: 1.5; stroke-linecap: round; stroke-dasharray: 2 6; }
.ag-branch circle { fill: #c9b7ff; }
.ag-fall circle { fill: #c9b7ff; opacity: 0; }
.ag-journey.is-near .ag-fall circle { animation: agJFall 2.4s ease-in infinite; }
@keyframes agJFall { 0% { transform: translate(0, 0); opacity: 0; } 12% { opacity: 0.9; } 100% { transform: translate(8px, 140px); opacity: 0; } }
.ag-plank { fill: #c9b7ff; opacity: 0; }
.ag-bridge-line { fill: none; stroke: #efe8ff; stroke-width: 2; stroke-linecap: round; }
.ag-mark line { stroke: rgba(201, 183, 255, 0.45); stroke-width: 1.5; transition: stroke 0.4s ease; }
.ag-mark circle { fill: #27145c; stroke: rgba(201, 183, 255, 0.6); stroke-width: 1.5; transition: fill 0.4s ease, stroke 0.4s ease; }
.ag-mark.is-on line { stroke: #c9b7ff; }
.ag-mark.is-on circle { fill: #c9b7ff; stroke: #fff; }
.ag-summit__core { fill: rgba(201, 183, 255, 0.45); transition: fill 0.4s ease; }
.ag-summit .ag-pulse { visibility: hidden; }
.ag-summit.is-on .ag-pulse { visibility: visible; }
.ag-summit.is-on .ag-summit__core { fill: #fff; }
.ag-dot__glow { fill: rgba(183, 156, 255, 0.22); }
.ag-dot__core { fill: #fff; }

/* ── 5. Contact ── */
.about-final-cta h2 { max-width: 18ch; }

/* ── Responsive ── */
@media (max-width: 980px) {
  .ag-hero__inner,
  .ag-story__grid { grid-template-columns: 1fr; }
  .ag-journey:not(.is-live) .ag-journey__steps { grid-template-columns: 1fr; max-width: 42rem; gap: 1.75rem; }
  .ag-hero__inner { padding-bottom: 4rem; }
}
@media (max-width: 700px) {
  .ag-hero__headline { font-size: clamp(2.5rem, 10vw, 3.4rem); }
  .ag-clients__grid { grid-template-columns: 1fr; }
  .about-actions .ag-text-link { align-self: center; }
  .ag-strip__inner { justify-content: flex-start; }
  .ag-strip__list { justify-content: flex-start; gap: 0.35rem 1.25rem; }
  .ag-strip__list li + li::before { content: none; }
}
@media (max-width: 759px) {
  .ag-journey.is-live .ag-journey__head { top: 4.9rem; gap: 0.75rem 1rem; }
  .ag-journey__title { font-size: 2rem; }
  .ag-journey.is-live .ag-journey__nav { gap: 0.45rem; }
  .ag-journey__dot { width: 24px; height: 24px; font-size: 0; }
  .ag-journey__track { left: 12px; right: 12px; }
  .ag-journey.is-live .ag-jstep h3 { font-size: 1.6rem; margin: 0.6rem 0 0.45rem; }
  .ag-journey.is-live .ag-jstep p { font-size: 0.97rem; line-height: 1.6; }
}

/* ── Reduced motion: everything in its finished state ── */
@media (prefers-reduced-motion: reduce) {
  .ag-js .reveal-fade { opacity: 1 !important; transform: none !important; transition: none !important; }
  .ag-journey * { animation: none !important; }
}
