/* Place the halo behind the clipped hexagon so its edge stays visible. */
#proyectos .model2-project-track .project-card::before {
  content: '';
  position: absolute;
  z-index: 0;
  top: 0;
  left: 2px;
  width: calc(100% - 4px);
  aspect-ratio: 1.48;
  background: radial-gradient(ellipse, var(--accent) 0 35%, transparent 72%);
  filter: blur(18px);
  transform: scale(1.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity .35s ease;
}
#proyectos.category-selected .model2-project-track .project-card::before {
  aspect-ratio: 1.45;
}
#proyectos .model2-project-track .project-card:is(:hover, :focus-within)::before {
  opacity: .82;
}
#proyectos .model2-project-track .project-photo {
  position: relative;
  z-index: 1;
}

/* Videos and remaining stills share the experience rail. */
#clientes .brand-ribbons + .client-section-heading { display: block; }
#clientes .client-experience-videos {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
  max-width: 1260px;
  margin: 0 auto 35px;
}
#clientes .client-experience-videos > * {
  min-width: 0;
  padding: 8px 8px 16px;
  border: 1px solid #253b50;
  border-radius: 14px;
  background: linear-gradient(150deg, #101920, #030607);
  text-align: left;
  animation: experience-border-glow 4s ease-in-out infinite;
}
#clientes .client-experience-video { position: relative; }
#clientes .experience-expand {
  position: absolute;
  z-index: 2;
  top: 18px;
  right: 18px;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid #75baff;
  border-radius: 8px;
  background: #020912d9;
  color: #fff;
  font: 28px/1 Arial, sans-serif;
  box-shadow: 0 0 12px #2389ff66;
}
#clientes .experience-expand:is(:hover, :focus-visible) {
  background: #1767bd;
  box-shadow: 0 0 18px #2389ffaa;
}
#experience-video-dialog {
  width: max-content;
  max-width: calc(100vw - 24px);
  max-height: calc(100dvh - 24px);
  padding: 16px;
  border: 1px solid #409dff;
  border-radius: 14px;
  background: #030913;
  box-shadow: 0 24px 80px #000d, 0 0 30px #2389ff66;
  overflow: auto;
}
#experience-video-dialog::backdrop { background: #000d; backdrop-filter: blur(7px); }
#experience-video-dialog .experience-dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 12px;
}
#experience-video-dialog h2 { margin: 0; font: 600 18px/1.3 Poppins, Arial, sans-serif; }
#experience-video-dialog .experience-dialog-close {
  flex: none;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid #517da9;
  border-radius: 50%;
  background: #07182a;
  color: #fff;
  font: 28px/1 Arial, sans-serif;
}
#experience-video-dialog video {
  display: block;
  width: auto;
  height: auto;
  max-width: calc(100vw - 56px);
  max-height: calc(100dvh - 110px);
  margin: auto;
  background: #000;
  object-fit: contain;
}
#clientes .client-experience-videos > :nth-child(2) { animation-delay: -1s; }
#clientes .client-experience-videos > :nth-child(3) { animation-delay: -2s; }
#clientes .client-experience-videos > :nth-child(4) { animation-delay: -3s; }
#clientes .client-experience-videos > :nth-child(5) { animation-delay: -4s; }
@keyframes experience-border-glow {
  0%, 100% {
    border-color: #253b50;
    box-shadow: 0 0 0 #2389ff00, inset 0 0 0 #2389ff00;
  }
  50% {
    border-color: #4aa5ff;
    box-shadow: 0 0 12px #2389ff88, 0 0 26px #2389ff3d, inset 0 0 10px #2389ff26;
  }
}
#clientes .client-experience-videos .ref-story {
  display: block;
  color: #fff;
}
#clientes .client-experience-videos .ref-story img {
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: 9px;
  object-fit: cover;
}
#clientes .client-experience-videos .ref-story[data-story="3"] img {
  object-position: 35% center;
}
#clientes .client-experience-video video {
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: 9px;
  background: #000;
  object-fit: cover;
}
#clientes .client-experience-video h3 {
  margin: 13px 10px 2px;
  font: 600 16px/1.25 Quedora, Arial, sans-serif;
  color: #fff;
}
#clientes .client-experience-video p {
  margin: 0 10px;
  color: #a9bccd;
  font: 400 12px/1.4 Poppins, Arial, sans-serif;
}
@media (max-width: 850px) {
  #clientes .client-experience-videos {
    display: flex;
    width: 100%;
    max-width: 100%;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    padding: 0 0 14px;
  }
  #clientes .client-experience-videos > * {
    flex: 0 0 clamp(180px, 28vw, 230px);
    scroll-snap-align: start;
  }
}
@media (prefers-reduced-motion: reduce) {
  #proyectos .model2-project-track .project-card::before { transition: none; }
  #clientes .client-experience-videos > * { animation: none; }
}
