/* ======================================================================
   Services Flow Section — light, live silk-wave background (per
   reference screenshot) + service photo medallions that float past
   one after another in a continuous marquee, sitting between the Hero
   and the Footer.
   ====================================================================== */

.services-flow {
  position: relative;
  overflow: hidden;
  background: #ffffff;
  padding: 100px 0 110px;
  isolation: isolate;
}

@media (max-width: 991px) {
  .services-flow { padding: 76px 0 84px; }
}
@media (max-width: 576px) {
  .services-flow { padding: 60px 0 68px; }
}

/* ---------- Live wave background ---------- */
.flow-waves {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
}

.flow-waves .flow-ribbon {
  transform-box: fill-box;
  transform-origin: center;
}

.flow-ribbon-a    { animation: flowDriftA 22s ease-in-out infinite; }
.flow-ribbon-b    { animation: flowDriftB 29s ease-in-out infinite; }
.flow-ribbon-warm { animation: flowDriftC 25s ease-in-out infinite; }
.flow-ribbon-aqua { animation: flowDriftB 34s ease-in-out infinite reverse; }

@keyframes flowDriftA {
  0%   { transform: translate(-3%, -2%) rotate(-1.4deg) scale(1); }
  50%  { transform: translate(2.5%, 3%) rotate(1.2deg) scale(1.05); }
  100% { transform: translate(-3%, -2%) rotate(-1.4deg) scale(1); }
}
@keyframes flowDriftB {
  0%   { transform: translate(3%, 2%) rotate(1deg) scale(1.02); }
  50%  { transform: translate(-2.5%, -3%) rotate(-1.4deg) scale(1); }
  100% { transform: translate(3%, 2%) rotate(1deg) scale(1.02); }
}
@keyframes flowDriftC {
  0%   { transform: translate(-2%, 2.5%) rotate(0.8deg) scale(1); }
  50%  { transform: translate(3%, -2%) rotate(-1deg) scale(1.04); }
  100% { transform: translate(-2%, 2.5%) rotate(0.8deg) scale(1); }
}

/* soft white vignette so content stays readable over the ribbons */
.flow-waves::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 15%, rgba(255,255,255,.55) 0%, rgba(255,255,255,.1) 35%, #ffffff 92%),
    linear-gradient(180deg, #ffffff 0%, rgba(255,255,255,.1) 20%, rgba(255,255,255,.1) 72%, #ffffff 100%);
}

/* ---------- Foreground content ---------- */
.services-flow .container {
  position: relative;
  z-index: 1;
}

.flow-eyebrow {
  display: inline-block;
  font-family: var(--font-secondary);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #7c5cff;
  margin-bottom: 14px;
}

.services-flow h2 {
  font-family: var(--font-secondary);
  color: var(--color-default);
  font-size: 34px;
  font-weight: 700;
  max-width: 720px;
  margin-bottom: 14px;
  line-height: 1.25;
}

.services-flow .flow-sub {
  color: rgba(10,13,19,.68);
  max-width: 620px;
  font-size: 16px;
  margin-bottom: 52px;
}

@media (max-width: 576px) {
  .services-flow h2 { font-size: 25px; }
  .services-flow .flow-sub { margin-bottom: 38px; font-size: 14.5px; }
}

/* ---------- Service photo marquee ---------- */
.flow-marquee {
  position: relative;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
}

.flow-track {
  display: flex;
  align-items: flex-start;
  gap: 26px;
  width: max-content;
  animation: flowMarquee 32s linear infinite;
}

.flow-marquee:hover .flow-track {
  animation-play-state: paused;
}

@keyframes flowMarquee {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.flow-medallion {
  --ring: rgba(13,66,255,.14);
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 130px;
  text-align: center;
  flex: 0 0 auto;
  animation: flowFloat 3.2s ease-in-out infinite;
}

@keyframes flowFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}

.flow-medallion-ring {
  position: relative;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  overflow: hidden;
  background-image: var(--photo);
  background-size: cover;
  background-position: center;
  box-shadow: 0 10px 24px rgba(20,20,50,.16), 0 0 0 4px #fff, 0 0 0 6px var(--ring);
  transition: box-shadow .3s ease, transform .3s ease;
}

.flow-medallion-ring::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10,13,19,0) 45%, rgba(10,13,19,.45) 100%);
}

.flow-medallion-badge {
  position: absolute;
  right: -2px;
  bottom: -2px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--badge, #0d42ff);
  border: 2px solid #fff;
  box-shadow: 0 3px 8px rgba(20,20,50,.25);
  z-index: 1;
}

.flow-medallion-badge i {
  font-size: 12px;
  color: #fff;
}

.flow-medallion:hover .flow-medallion-ring {
  box-shadow: 0 14px 30px rgba(20,20,50,.22), 0 0 0 4px #fff, 0 0 0 7px var(--ring);
  transform: scale(1.06);
}

.flow-medallion span {
  margin-top: 12px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--color-default);
  line-height: 1.35;
}

@media (max-width: 480px) {
  .flow-medallion { width: 92px; }
  .flow-medallion-ring { width: 68px; height: 68px; }
  .flow-medallion-badge { width: 22px; height: 22px; }
  .flow-medallion-badge i { font-size: 10px; }
  .flow-medallion span { font-size: 11px; margin-top: 9px; }
}

/* ---------- Motion & performance considerations ---------- */
@media (prefers-reduced-motion: reduce) {
  .flow-ribbon-a, .flow-ribbon-b, .flow-ribbon-warm, .flow-ribbon-aqua,
  .flow-track, .flow-medallion {
    animation: none !important;
  }
}
