/* ========================================================================== 
   What We Do — page template styles
   Page-specific sections and design tokens. Shared hero, CTA, container,
   buttons and section headings live in the global style.css.
   ========================================================================== */

html.wwd-sticky-root,
html.wwd-sticky-root body {
  /* The global theme sets overflow-x:hidden on body. That promotes the
     computed overflow-y value to auto and makes body the sticky containing
     block, so sticky children scroll away with the document. `clip` prevents
     horizontal spill without creating a scrolling ancestor. */
  overflow-x: clip !important;
  overflow-y: visible !important;
}

.wwd-page {

  color: var(--cn-white);
  font-family: var(--cn-font, "Inter", "DM Sans", sans-serif);
  /* Unlike overflow:hidden, clip does not create a scroll container that
     prevents position:sticky from following the viewport. */
  overflow-x: clip;
  position: relative;
  isolation: isolate;
}

.wwd-page * {
  box-sizing: border-box;
}

.wwd-page img {
  max-width: 100%;
  display: block;
}

/* Keep the 4K showreel within the viewport instead of its native dimensions. */
.wwd-page .cn-showreel {
  display: grid;
  width: 100%;
  max-height: 85vh;
  max-height: 85svh;
  place-items: center;
  overflow: hidden;
  background: var(--cn-black, #000);
}

.wwd-page .cn-showreel__video {
  display: block;
  width: 100%;
  height: auto;
  max-height: 85vh;
  max-height: 85svh;
  object-fit: contain;
}

/* Shared .wwd-container layout lives in the global style.css. */

.wwd-auto-container {
  max-width: var(--cn-auto-container);
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 64px);
}

/* Shared heading and button styles live in the global style.css. */

/* ---------------------------------------------------------------------- */
/* Gradient mesh blobs — used in the hero and the closing CTA             */
/* ---------------------------------------------------------------------- */

.wwd-mesh {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

.wwd-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.75;
  will-change: transform;
}

.wwd-blob--1 {
  width: 46vw;
  height: 46vw;
  max-width: 640px;
  max-height: 640px;
  top: -10%;
  left: -8%;
  background: radial-gradient(circle at 30% 30%, var(--cn-orange), transparent 70%);
  animation: wwdFloatA 22s ease-in-out infinite;
}

.wwd-blob--2 {
  width: 40vw;
  height: 40vw;
  max-width: 560px;
  max-height: 560px;
  top: 10%;
  right: -6%;
  background: radial-gradient(circle at 60% 40%, var(--cn-pink), transparent 70%);
  animation: wwdFloatB 26s ease-in-out infinite;
}

.wwd-blob--3 {
  width: 44vw;
  height: 44vw;
  max-width: 600px;
  max-height: 600px;
  bottom: -18%;
  left: 18%;
  background: radial-gradient(circle at 50% 50%, var(--cn-red), transparent 72%);
  animation: wwdFloatC 30s ease-in-out infinite;
}

.wwd-blob--4 {
  width: 26vw;
  height: 26vw;
  max-width: 380px;
  max-height: 380px;
  bottom: 6%;
  right: 12%;
  background: radial-gradient(circle, var(--cn-purple), transparent 72%);
  opacity: 0.5;
  animation: wwdFloatA 18s ease-in-out infinite reverse;
}

@keyframes wwdFloatA {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(4%, 6%) scale(1.08); }
  66% { transform: translate(-3%, 3%) scale(0.95); }
}

@keyframes wwdFloatB {
  0%, 100% { transform: translate(0, 0) scale(1); }
  40% { transform: translate(-6%, 4%) scale(1.1); }
  70% { transform: translate(3%, -4%) scale(0.92); }
}

@keyframes wwdFloatC {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(5%, -5%) scale(1.12); }
}

.wwd-mesh__vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 30%, rgba(0, 0, 0, 0.15) 0%, rgba(0, 0, 0, 0.72) 62%, var(--cn-bg) 100%);
}

.wwd-mesh__fade {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 40%;
  background: linear-gradient(to bottom, transparent, var(--cn-bg));
}

/* Shared hero styles, responsive rules and scroll cue live in style.css. */

/* ---------------------------------------------------------------------- */
/* Manifesto — scroll-driven circle pattern with right-aligned copy        */
/* ---------------------------------------------------------------------- */

.wwd-manifesto {
  position: relative;
  padding: clamp(100px, 14vw, 200px) 0;
  background: transparent;
  overflow: hidden;
}

.wwd-manifesto-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.9fr);
  align-items: center;
  gap: clamp(56px, 8vw, 120px);
  max-width: 1440px;
}

.wwd-manifesto-pattern {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(100%, 540px);
  aspect-ratio: 1;
  justify-self: start;
  isolation: isolate;
  pointer-events: none;
}

.wwd-solving-orb {
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 1;
}

.wwd-manifesto-copy {
  max-width: 620px;
  margin-left: auto;
  text-align: left;
}

.wwd-manifesto-heading {
  font-family: var(--cn-font, "Inter", "DM Sans", sans-serif);
  font-size: clamp(2rem, 4.2vw, 3.4rem);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 32px;
}

.wwd-manifesto-body p {
  font-size: var(--full-website-paragraph-font-size);
  line-height: 1.7;
  color: var(--cn-muted);
  margin: 0 0 18px;
}

.wwd-manifesto-body p:last-of-type {
  margin-bottom: 0;
}

.wwd-manifesto-action {
  display: flex;
  margin-top: 40px;
}

.wwd-manifesto-label {
  margin-bottom: 32px;
}

.wwd-manifesto-text {
  font-size: clamp(1.6rem, 3.4vw, 2.7rem);
  line-height: 1.42;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.wwd-word {
  color: var(--cn-muted-2);
  transition: color 0.2s linear;
}

.wwd-word.is-lit {
  color: var(--cn-white);
}

/* ---------------------------------------------------------------------- */
/* Services                                                                */
/* ---------------------------------------------------------------------- */

.wwd-services {
  position: relative;
  padding: clamp(80px, 10vw, 140px) 0;
  border-top: 1px solid var(--cn-line);
}

.wwd-services-head {
  position: sticky;
  top: 120px;
}

/* Reusable sticky-content utility.
   Add this class to a grid/flex child and it will remain visible until the
   bottom edge of its containing section is reached. */
.wwd-sticky-content {
  position: sticky;
  top: var(--cn-sticky-top, 120px);
  align-self: start;
  height: fit-content;
  z-index: 2;
}

.wwd-services-head .wwd-eyebrow {
  margin-bottom: 24px;
}

.wwd-section-copy {
  color: var(--cn-muted);
  font-size: 1.05rem;
  line-height: 1.65;
  max-width: 42ch;
  margin: 0 0 32px;
}

.wwd-services-list {
  border-top: 1px solid var(--cn-line);
}

.wwd-services-list-column {
  min-width: 0;
}

.wwd-services-list-column > .wwd-string-sound {
  margin: 0 0 22px;
}

.cn-home-services-module .wwd-services-list-column > .wwd-string-sound {
  width: fit-content;
  margin-left: auto;
}

.wwd-service-row {
  display: grid;
  grid-template-columns: minmax(160px, 300px) 1fr;
  gap: clamp(24px, 4vw, 56px);
  border-bottom: 1px solid var(--cn-line);
  padding: clamp(30px, 4vw, 46px) 0;
}

.wwd-service-title {
  font-size: clamp(1.3rem, 2.2vw, 1.85rem);
  font-weight: 500;
  line-height: 1.2;
  margin: 0;
  color: var(--cn-white);
}

.wwd-service-desc {
  color: var(--cn-muted);
  max-width: 60ch;
  line-height: 1.65;
  margin: 0;
  font-size: --var(--full-website-paragraph-font-size);
}

.wwd-service-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 0;
  color: var(--cn-white);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  border-bottom: 1px solid var(--cn-line);
  padding-bottom: 2px;
}

.js-wwd-hover-item {
  cursor: pointer;
}

.wwd-service-row.has-string {
  position: relative;
  border-bottom-color: transparent;
}

.wwd-service-string {
  position: absolute;
  left: 0;
  bottom: -17px;
  width: 100%;
  height: 34px;
  overflow: visible;
  pointer-events: none;
  color: var(--cn-white);
}

.wwd-service-string path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.wwd-string-sound {
  display: block;
  margin-top: 22px;
  padding: 8px 12px;
  border: 1px solid var(--cn-line);
  border-radius: 999px;
  background: transparent;
  color: var(--cn-muted);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.wwd-string-sound:hover,
.wwd-string-sound:focus-visible {
  color: var(--cn-white);
  border-color: currentColor;
}

/* Cursor-follow image preview shown while hovering a service row.
   Position (x/y) is driven by GSAP quickTo in JS for smooth trailing;
   only opacity/scale are handled here so the two never fight. */
.wwd-hover-preview {
  position: fixed;
  top: 0;
  left: 0;
  width: 260px;
  height: 180px;
  z-index: 60;
  pointer-events: none;
}

.wwd-hover-preview-inner {
  width: 100%;
  height: 100%;
  border-radius: 18px;
  overflow: hidden;
  background: var(--cn-bg-soft);
  box-shadow: 0 24px 60px -16px rgba(0, 0, 0, 0.65);
  opacity: 0;
  transform: scale(0.85) rotate(-2deg);
  transition: opacity 0.35s ease, transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.wwd-hover-preview-inner.is-active {
  opacity: 1;
  transform: scale(1) rotate(0deg);
}

.wwd-hover-preview-img,
.wwd-hover-preview-fallback {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}

.wwd-hover-preview-fallback {
  background: linear-gradient(135deg, var(--cn-orange), var(--cn-pink) 60%, var(--cn-purple));
}

@media (hover: none), (max-width: 1024px) {
  .wwd-hover-preview {
    display: none;
  }
}

/* ---------------------------------------------------------------------- */
/* Work / selected projects                                               */
/* ---------------------------------------------------------------------- */

.wwd-work {
  padding: clamp(80px, 10vw, 140px) 0;
  /*border-top: 1px solid var(--cn-line);*/
}

.wwd-work-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 56px;
  flex-wrap: wrap;
}

.wwd-work-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 40px);
}

.wwd-work-card {
  position: relative;
  text-decoration: none;
  color: var(--cn-white);
  display: flex;
  flex-direction: column;
}

.wwd-work-media {
  position: relative;
  border-radius: 26px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  isolation: isolate;
}

.wwd-work-thumb {
  position: absolute;
  inset: 0;
}

.wwd-page .wwd-work-thumb .card-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.wwd-thumb { background: linear-gradient(135deg, var(--cn-cursor-big), var(--cn-cursor-accent) 60%, var(--cn-cursor-big)); }


.wwd-work-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0) 40%);
  z-index: 1;
  pointer-events: none;
}

.wwd-work-capsules {
  position: absolute;
  top: 20px;
  left: 20px;
  right: 20px;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.wwd-capsule {
  display: inline-flex;
  align-items: center;
  padding: 7px 16px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--cn-white);
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(248, 244, 240, 0.18);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.wwd-capsule--active {
  background: transparent;
  border-color: rgba(248, 244, 240, 0.85);
}

.wwd-work-info {
  padding-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.wwd-work-title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: clamp(1.1rem, 1.6vw, 1.3rem);
  font-weight: 600;
  margin: 0;
}

.wwd-work-arrow {
  flex: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(248, 244, 240, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), background 0.3s ease, color 0.3s ease;
}

.wwd-work-card:hover .wwd-work-arrow {
  transform: rotate(45deg);
  background: var(--cn-white);
  color: var(--cn-black);
}

.wwd-work-desc {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--cn-muted);
  margin: 0;
}

/* ---------------------------------------------------------------------- */
/* Testimonials                                                           */
/* ---------------------------------------------------------------------- */

.wwd-testimonials {
  padding: clamp(80px, 10vw, 140px) 0;
}

.wwd-testimonials-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 56px;
  flex-wrap: wrap;
}

.wwd-slider-arrows {
  display: flex;
  gap: 12px;
}

.wwd-arrow-btn {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--cn-line);
  background: transparent;
  color: var(--cn-white);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease, border-color 0.3s ease;
}

.wwd-arrow-btn:hover {
  background: rgba(248, 244, 240, 0.08);
  border-color: rgba(248, 244, 240, 0.4);
}

.wwd-testimonials-viewport {
  overflow: hidden;
}

.wwd-testimonials-track {
  display: flex;
  gap: clamp(20px, 3vw, 32px);
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.wwd-testimonial-card {
  flex: 0 0 calc(33.333% - 22px);
  background: rgba(248, 244, 240, 0.04);
  border: 1px solid var(--cn-line);
  border-radius: 24px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.wwd-testimonial-quote {
  font-size: 1.02rem;
  line-height: 1.65;
  color: var(--cn-muted);
  flex: 1;
}

.wwd-testimonial-quote::before {
  content: "\201C";
}

.wwd-testimonial-quote::after {
  content: "\201D";
}

.wwd-testimonial-meta {
  display: flex;
  align-items: center;
  gap: 14px;
}

.wwd-testimonial-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  overflow: hidden;
  flex: none;
  background: linear-gradient(135deg, var(--cn-orange), var(--cn-pink));
}

.wwd-testimonial-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.wwd-testimonial-name {
  font-weight: 600;
  font-size: 14px;
}

.wwd-testimonial-role {
  font-size: 12px;
  color: var(--cn-muted-2);
}

/* ---------------------------------------------------------------------- */
/* Clients                                                                 */
/* ---------------------------------------------------------------------- */

.wwd-clients {
  padding: clamp(70px, 9vw, 120px) 0;
  text-align: center;
}

.wwd-clients-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  background: var(--cn-line);
  border: 1px solid var(--cn-line);
  border-radius: 20px;
  overflow: hidden;
}

.wwd-client-logo {
  background: var(--cn-bg);
  padding: 34px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 110px;
  filter: grayscale(1) brightness(1.6) opacity(0.55);
  transition: filter 0.4s ease, transform 0.4s ease;
}

.wwd-client-logo:hover {
  filter: grayscale(0) brightness(1) opacity(1);
  transform: translateY(-2px);
}

.wwd-client-logo img {
  max-height: 34px;
  width: auto;
}

/* Shared closing CTA styles live in the global style.css. */

/* ---------------------------------------------------------------------- */
/* Scroll-reveal utility (driven by JS toggling .is-visible)              */
/* ---------------------------------------------------------------------- */

.wwd-reveal {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.wwd-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------------------------------------------------------------------- */
/* Responsive                                                              */
/* ---------------------------------------------------------------------- */

@media (max-width: 1024px) {
  .wwd-manifesto-inner {
    grid-template-columns: minmax(260px, 0.8fr) minmax(360px, 1fr);
    gap: 36px;
  }

  .wwd-manifesto-pattern {
    width: min(100%, 390px);
  }

  .wwd-services-head,
  .wwd-sticky-content {
    position: static;
    margin-bottom: 40px;
  }

  .wwd-work-grid {
    grid-template-columns: 1fr;
  }

  .wwd-testimonial-card {
    flex: 0 0 calc(50% - 16px);
  }

  .wwd-clients-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Shared mobile layout for manifesto sections on every template. */
@media (max-width: 768px) {
  .wwd-manifesto {
    text-align: center;
  }

  .wwd-manifesto-inner {
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
    min-width: 0;
    padding-inline: 0;
    gap: 32px;
    justify-items: center;
  }

  .wwd-manifesto-pattern {
    order: 2;
    width: min(100%, 360px);
    min-width: 0;
    justify-self: center;
    margin-inline: auto;
  }

  .wwd-manifesto-copy {
    order: 1;
    width: 100%;
    min-width: 0;
    margin-inline: auto;
    text-align: center;
    overflow-wrap: anywhere;
  }

  .wwd-manifesto-heading,
  .wwd-manifesto-body {
    text-align: center;
  }

  .wwd-manifesto-action {
    justify-content: center;
  }
}

@media (max-width: 640px) {
  .wwd-manifesto {
    padding: 88px 0;
  }

  .wwd-service-row {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .wwd-testimonial-card {
    flex: 0 0 85%;
  }

  .wwd-clients-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .wwd-work-head,
  .wwd-testimonials-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .wwd-blob {
    filter: blur(50px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .wwd-blob {
    animation: none !important;
  }

  .wwd-reveal {
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}
