/* ===== SERVICES PAGE — gold circles on desktop / tablet (phones keep the cinematic cards) ===== */
@media screen and (min-width: 768px) {
  /* calm, dark stage behind the circles (the site photo stays faintly visible) */
  .work-page-section:has(.services-grid) {
    background: radial-gradient(ellipse at 50% 30%, rgba(40,31,12,.55) 0%, rgba(6,6,7,.9) 60%, rgba(5,5,5,.95) 100%);
  }
  .services-grid {
    display: flex !important; flex-wrap: wrap; justify-content: center;
    gap: 70px 56px !important; margin-top: 80px !important; padding-bottom: 40px;
  }
  .services-grid .service-card {
    --c: 280px;
    position: relative; flex: 0 1 320px; display: flex !important; flex-direction: column; align-items: center;
    text-align: center; padding-top: 22px;
    background: none !important; border: 0 !important; border-radius: 0; box-shadow: none !important; overflow: visible !important;
    transition: transform .5s cubic-bezier(.22,1,.36,1) !important;
  }
  .services-grid .service-card:hover { transform: translateY(-8px) !important; box-shadow: none !important; }

  /* the photo as a circle */
  .services-grid .service-card .service-image {
    width: var(--c) !important; height: var(--c) !important; border-radius: 50%; object-fit: cover;
    position: relative; z-index: 1; display: block;
    box-shadow: 0 30px 60px rgba(0,0,0,.6), 0 0 0 6px #0b0b0d;
    filter: brightness(.88) saturate(.95);
    transition: transform .9s cubic-bezier(.22,1,.36,1), filter .6s ease, clip-path 1.2s cubic-bezier(.77,0,.18,1);
    clip-path: circle(50% at 50% 50%);
  }
  .services-grid .service-card:hover .service-image { transform: scale(1.05); filter: brightness(1) saturate(1.05); }

  /* spinning gold ring */
  .services-grid .service-card::before {
    content: ""; position: absolute; z-index: 0; pointer-events: none;
    top: calc(22px - 14px); left: 50%; width: calc(var(--c) + 28px); height: calc(var(--c) + 28px); margin-left: calc((var(--c) + 28px) / -2);
    border-radius: 50%;
    background: conic-gradient(from 0deg, #d4af37, rgba(212,175,55,0) 28%, #f3dc8e 50%, rgba(212,175,55,0) 78%, #d4af37);
    -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 2px), #000 calc(100% - 2px));
            mask: radial-gradient(farthest-side, transparent calc(100% - 2px), #000 calc(100% - 2px));
    animation: svcRingSpin 14s linear infinite;
    transition: opacity .8s ease;
  }
  /* outer dashed orbit, turning the other way */
  .services-grid .service-card::after {
    content: ""; position: absolute; z-index: 0; pointer-events: none;
    top: calc(22px - 30px); left: 50%; width: calc(var(--c) + 60px); height: calc(var(--c) + 60px); margin-left: calc((var(--c) + 60px) / -2);
    border-radius: 50%; border: 1px dashed rgba(212,175,55,.28);
    animation: svcRingSpin 40s linear infinite reverse;
    transition: border-color .5s ease, opacity .8s ease;
  }
  .services-grid .service-card:hover::before { animation-duration: 3.5s; }
  .services-grid .service-card:hover::after { border-color: rgba(212,175,55,.6); }

  /* number badge on the ring */
  .services-grid .svc-m-num {
    display: flex !important; align-items: center; justify-content: center;
    position: absolute; z-index: 2; top: 30px; left: calc(50% + 92px);
    width: 50px; height: 50px; border-radius: 50%;
    background: linear-gradient(180deg, #f6dd8d, #d4af37 60%, #ad8222);
    color: #111; font-family: "Cairo", sans-serif; font-size: 15px; font-weight: 700; letter-spacing: .04em;
    box-shadow: 0 8px 22px rgba(0,0,0,.55), 0 0 0 4px #0b0b0d;
    transition: transform .6s cubic-bezier(.22,1,.36,1);
  }
  .services-grid .svc-m-num::after { display: none; }
  [dir="rtl"] .services-grid .svc-m-num { left: auto; right: calc(50% + 92px); }
  .services-grid .service-card:hover .svc-m-num { transform: rotate(360deg) scale(1.08); }

  /* text under the circle */
  .services-grid .service-content { padding: 40px 6px 0 !important; max-width: 320px; }
  .services-grid .service-content h3 {
    font-family: 'Gilda Display', serif !important; font-weight: 400 !important; font-size: 30px !important;
    line-height: 1.15 !important; letter-spacing: .01em !important; text-transform: none !important; margin: 0 0 8px !important;
    background: linear-gradient(180deg, #fff3c4 0%, #f1d27a 30%, #d4af37 55%, #b0852a 80%, #f3dc8e 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent !important;
  }
  [dir="rtl"] .services-grid .service-content h3 { font-family: 'El Messiri', serif !important; font-weight: 700 !important; letter-spacing: 0 !important; }
  .services-grid .service-content h4 { font-size: 14px !important; font-weight: 500 !important; color: #e9dcbb !important; margin: 0 0 10px !important; line-height: 1.5 !important; }
  .services-grid .service-content p {
    font-size: 13px !important; line-height: 1.75 !important; color: rgba(255,255,255,.62) !important; margin: 0 !important;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .services-grid .svc-m-cta {
    display: inline-flex !important; align-items: center; gap: 10px; margin-top: 18px; padding: 0 0 6px;
    font-family: "Cairo", sans-serif; font-size: 13px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase;
    color: #e8c770; position: relative;
  }
  [dir="rtl"] .services-grid .svc-m-cta { letter-spacing: 0; font-size: 14px; }
  .services-grid .svc-m-cta::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
    background: linear-gradient(90deg, transparent, #d4af37, transparent);
    transform: scaleX(.35); transition: transform .5s ease;
  }
  .services-grid .service-card:hover .svc-m-cta::after { transform: scaleX(1); }
  .services-grid .svc-m-cta i { font-style: normal; transition: transform .4s ease; }
  .services-grid .service-card:hover .svc-m-cta i { transform: translateX(6px); }
  [dir="rtl"] .services-grid .service-card:hover .svc-m-cta i { transform: translateX(-6px); }

  /* ---- entrance: the photo opens like a camera iris, then the text rises ---- */
  .svc-c-ready .service-card .service-image { clip-path: circle(0% at 50% 50%); transform: scale(1.15); }
  .svc-c-ready .service-card::before,
  .svc-c-ready .service-card::after { opacity: 0; }
  .svc-c-ready .service-card .svc-m-num { transform: scale(0) rotate(-180deg); }
  .svc-c-ready .service-card .service-content > * { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .8s cubic-bezier(.22,1,.36,1); }

  .svc-c-ready .service-card.svc-c-in .service-image { clip-path: circle(50% at 50% 50%); transform: none; }
  .svc-c-ready .service-card.svc-c-in::before,
  .svc-c-ready .service-card.svc-c-in::after { opacity: 1; transition-delay: calc(var(--svc-delay, 0s) + .5s); }
  .svc-c-ready .service-card.svc-c-in .svc-m-num { transform: none; transition-delay: calc(var(--svc-delay, 0s) + .8s); }
  .svc-c-ready .service-card.svc-c-in .service-content > * { opacity: 1; transform: none; }
  .svc-c-ready .service-card.svc-c-in .service-content > :nth-child(1) { transition-delay: calc(var(--svc-delay, 0s) + .55s); }
  .svc-c-ready .service-card.svc-c-in .service-content > :nth-child(2) { transition-delay: calc(var(--svc-delay, 0s) + .65s); }
  .svc-c-ready .service-card.svc-c-in .service-content > :nth-child(3) { transition-delay: calc(var(--svc-delay, 0s) + .75s); }
  .svc-c-ready .service-card.svc-c-in .service-content > :nth-child(4) { transition-delay: calc(var(--svc-delay, 0s) + .85s); }
  .svc-c-ready .service-card.svc-c-in:hover .service-image { transform: scale(1.05); }
  .svc-c-ready .service-card.svc-c-in:hover .svc-m-num { transform: rotate(360deg) scale(1.08); transition-delay: 0s; }
}
@keyframes svcRingSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .services-grid .service-card::before, .services-grid .service-card::after { animation: none !important; }
}
