/* Clients marquee, project portfolio and media lightbox. */

/* ---------- Clients & partners: full-bleed logo marquee ---------- */
.partners-strip.client-showcase{background:#f7f7f2;padding-block:64px 70px;border-bottom:1px solid var(--line);overflow:hidden}
.client-showcase .partners-heading{align-items:end;margin-bottom:34px;gap:30px}
.client-showcase .partners-heading h2{font-size:31px;line-height:1.4;margin-top:12px}
.client-showcase .partners-aside{display:flex;align-items:center;gap:18px}
.client-showcase .partners-heading p{font-size:13px;line-height:1.9;max-width:370px;color:var(--muted)}
.marquee-toggle{flex-shrink:0;width:42px;height:42px;display:grid;place-items:center;padding:0;border:1px solid #c9ccc0;border-radius:50%;background:#fff;color:var(--ink);cursor:pointer;transition:border-color .2s,background .2s}
.marquee-toggle:hover{border-color:var(--bronze);background:#fbfaf6}
.marquee-toggle:focus-visible{outline:2px solid var(--bronze);outline-offset:3px}
.marquee-toggle[hidden]{display:none}
.marquee-toggle svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}
.marquee-toggle .icon-play{display:none;fill:currentColor;stroke-width:1.4}
.marquee-toggle[aria-pressed=true] .icon-play{display:block}
.marquee-toggle[aria-pressed=true] .icon-pause{display:none}
.logo-marquee{position:relative;direction:ltr}
.logo-track{display:block}
.logo-set{display:flex;flex-wrap:wrap;justify-content:center;flex-shrink:0;margin:0 auto;padding:0 var(--gutter);list-style:none;max-width:1600px}
.logo-marquee .client-logo{flex:0 0 auto;width:200px;height:112px;margin:8px;display:grid;place-items:center;padding:16px 22px;background:#fff;border:1px solid #e3e5dc;transition:border-color .3s}
.logo-marquee .client-logo:hover{border-color:#cdbb9a}
.logo-marquee .client-logo img{display:block;width:150px;height:56px;max-width:100%;object-fit:contain}
.logo-marquee .logo-ksu img{height:52px}
.logo-marquee .logo-kfsh img{height:60px}
.logo-marquee .logo-othaimmall img,.logo-marquee .logo-panda img{height:72px}
.logo-marquee .logo-aldrees img{height:62px}
.logo-marquee .logo-autostar img{width:140px;height:65px;object-fit:cover}
.logo-marquee .logo-aljomaih img{width:100px;height:65px;object-fit:cover}
.logo-marquee.is-animated{overflow:hidden;-webkit-mask-image:linear-gradient(90deg,transparent,#000 8%,#000 92%,transparent);mask-image:linear-gradient(90deg,transparent,#000 8%,#000 92%,transparent)}
.logo-marquee.is-animated .logo-track{display:flex;width:max-content;animation:marquee-left var(--marquee-duration,60s) linear infinite;will-change:transform}
html[dir=rtl] .logo-marquee.is-animated .logo-track{animation-name:marquee-right}
.logo-marquee.is-animated .logo-set{flex-wrap:nowrap;padding:0;margin:0;max-width:none}
.logo-marquee.is-animated .client-logo{margin:0 9px}
.logo-marquee.is-paused .logo-track{animation-play-state:paused}
@media(hover:hover){.logo-marquee:hover .logo-track{animation-play-state:paused}}
@keyframes marquee-left{from{transform:translate3d(0,0,0)}to{transform:translate3d(calc(-1 * var(--set-width,0px)),0,0)}}
@keyframes marquee-right{from{transform:translate3d(calc(-1 * var(--set-width,0px)),0,0)}to{transform:translate3d(0,0,0)}}

/* ---------- Projects ---------- */
.projects{background:var(--forest);color:var(--paper);position:relative;overflow:hidden}
.projects:before{content:"";position:absolute;inset:0;background-image:linear-gradient(#b1c6bc08 1px,transparent 1px),linear-gradient(90deg,#b1c6bc08 1px,transparent 1px);background-size:70px 70px;pointer-events:none}
.projects .page-shell{position:relative}
.projects .section-heading>p{color:#b9c2b5}
.projects .muted-heading{color:#8e9a8c}
.projects button{font:inherit;color:inherit}
.projects button:focus-visible,.projects a:focus-visible{outline:2px solid var(--sand);outline-offset:3px}
.project-feature{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);background:#222e2b;border:1px solid #ffffff17}
.project-feature-media{position:relative;aspect-ratio:16/9;background:#111a18;overflow:hidden;isolation:isolate}
.project-video{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.media-open{position:absolute;inset:0;z-index:1;display:grid;place-items:center;padding:0;border:0;background:linear-gradient(180deg,#0d151300 55%,#0d151399);cursor:pointer}
.media-play{width:66px;height:66px;border-radius:50%;display:grid;place-items:center;background:#f4f2ebeb;color:var(--forest);box-shadow:0 12px 34px #0007;transition:transform .3s ease,opacity .3s ease}
.media-play svg{width:24px;height:24px;fill:currentColor;margin-left:4px}
.media-open:hover .media-play{transform:scale(1.07)}
.project-feature-media.is-playing .media-play{opacity:0;transform:scale(.85)}
.project-feature-media.is-playing .media-open:hover .media-play,.project-feature-media.is-playing .media-open:focus-visible .media-play{opacity:1;transform:none}
.media-badge{position:absolute;z-index:2;top:16px;inset-inline-start:16px;display:flex;align-items:center;gap:9px;padding:7px 12px;background:#0f1816b8;-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);font-size:11px;color:#ece8dd;pointer-events:none}
.live-dot{width:7px;height:7px;border-radius:50%;background:var(--sand);box-shadow:0 0 0 4px #d5b88a2e}
.project-feature-media.is-playing .live-dot{animation:livePulse 1.8s ease-in-out infinite}
@keyframes livePulse{50%{opacity:.35}}
.project-feature-copy{padding:clamp(28px,3.2vw,54px);display:flex;flex-direction:column;justify-content:center;min-width:0}
.project-kicker{font-size:11px;color:var(--sand);letter-spacing:.4px}
.project-feature-copy h3{font-size:clamp(28px,2.6vw,40px);font-weight:500;line-height:1.35;margin-top:12px;letter-spacing:-.5px}
.project-meta{display:flex;gap:36px;margin:22px 0 0;padding:15px 0;border-block:1px solid #ffffff1f}
.project-meta dt{font-size:10px;color:#9fab9c}
.project-meta dd{margin:4px 0 0;font-size:14px}
.project-feature-copy>p{font-size:14px;line-height:2;color:#c9d0c4;margin-top:20px}
.project-actions{display:flex;flex-wrap:wrap;align-items:center;gap:14px 30px;margin-top:26px}
.project-gallery-button{display:inline-flex;align-items:center;gap:12px;min-height:50px;padding:10px 20px;border:1px solid var(--sand);background:transparent;font-size:13px;cursor:pointer;transition:background .2s,color .2s}
.project-gallery-button:hover{background:var(--sand);color:var(--forest)}
.gallery-count{min-width:24px;height:24px;padding:0 7px;border-radius:12px;display:grid;place-items:center;background:#ffffff1c;font:11px monospace}
.projects .project-actions .text-link{margin-top:0;color:var(--paper);border-color:#ffffff47}
.projects .project-actions .text-link:hover{color:var(--sand)}
.project-thumbs{grid-column:1/-1;display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:1px;margin:0;padding:0;list-style:none;border-top:1px solid #ffffff17;background:#ffffff17}
.project-thumbs li{min-width:0}
.project-thumbs button{position:relative;display:block;width:100%;aspect-ratio:4/3;padding:0;border:0;background:#111a18;overflow:hidden;cursor:pointer}
.project-thumbs img{width:100%;height:100%;object-fit:cover;opacity:.86;transition:transform .6s ease,opacity .3s}
.project-thumbs img.keep-right{object-position:100% 50%}
.project-thumbs button:hover img,.project-thumbs button:focus-visible img{transform:scale(1.05);opacity:1}
.project-thumbs button:focus-visible{outline-offset:-3px}
.thumb-play{position:absolute;top:50%;left:50%;width:40px;height:40px;margin:-20px 0 0 -20px;border-radius:50%;display:grid;place-items:center;background:#f4f2ebeb;color:var(--forest);box-shadow:0 6px 18px #0007;transition:transform .3s ease;pointer-events:none}
.thumb-play svg{width:15px;height:15px;fill:currentColor;margin-left:3px}
.project-thumbs button:hover .thumb-play,.project-thumbs button:focus-visible .thumb-play{transform:scale(1.08)}
.thumb-tag{position:absolute;bottom:8px;inset-inline-start:8px;padding:3px 9px;font-size:10px;line-height:1.7;background:#0f1816cc;color:#ebe6d9}
.thumb-tag.site{background:#d5b88aeb;color:var(--forest)}
.project-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:22px;margin-top:22px}
.project-card{display:flex;flex-direction:column;min-width:0;background:#222e2b;border:1px solid #ffffff17}
.project-card-media{position:relative;display:block;width:100%;aspect-ratio:4/3;padding:0;border:0;background:#111a18;overflow:hidden;cursor:pointer}
.project-card-media img{width:100%;height:100%;object-fit:cover;transition:transform .7s ease}
.project-card-media:hover img,.project-card-media:focus-visible img{transform:scale(1.045)}
.project-card-media:focus-visible{outline-offset:-3px}
.project-card-media .media-play{position:absolute;top:50%;left:50%;width:58px;height:58px;transform:translate(-50%,-50%)}
.project-card-media:hover .media-play{transform:translate(-50%,-50%) scale(1.07)}
.media-count{position:absolute;bottom:12px;inset-inline-end:12px;display:flex;align-items:center;gap:6px;padding:5px 10px;background:#0f1816cc;color:#f1eee6;font-size:11px;direction:ltr}
.media-count svg{width:15px;height:15px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linejoin:round}
.project-card-body{padding:22px 24px 26px}
.project-card-body h3{font-size:21px;font-weight:500;line-height:1.5;margin-top:8px}
.project-card-body p{font-size:13px;line-height:1.95;color:#b9c2b5;margin-top:10px}
.projects-cta{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-top:22px;padding:26px 30px;border:1px solid #d5b88a55;background:linear-gradient(90deg,#d5b88a17,#d5b88a00)}
html[dir=rtl] .projects-cta{background:linear-gradient(270deg,#d5b88a17,#d5b88a00)}
.projects-cta>div>strong{display:block;font-size:20px;font-weight:500;line-height:1.5}
.projects-cta>div>span{display:block;font-size:13px;color:#b9c2b5;margin-top:4px}
.projects-cta .contact-button{flex-shrink:0}
html[dir=ltr] .project-feature-copy h3{letter-spacing:-.8px;line-height:1.2}

/* ---------- Lightbox ---------- */
html:has(.lightbox[open]){overflow:hidden}
dialog.lightbox{width:100%;height:100%;max-width:none;max-height:none;margin:0;padding:0;border:0;background:#0b1211f5;color:var(--paper);box-shadow:none;overflow:hidden}
dialog.lightbox[open]{display:flex;flex-direction:column}
dialog.lightbox::backdrop{background:#0b1211e6}
.lightbox button{font:inherit;color:inherit;cursor:pointer}
.lightbox button:focus-visible{outline:2px solid var(--sand);outline-offset:3px}
.lightbox-bar{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:14px clamp(16px,3vw,32px) 10px}
.lightbox-heading{display:flex;align-items:baseline;gap:14px;min-width:0}
.lightbox-heading strong{font-size:15px;font-weight:500;line-height:1.6}
#lightbox-counter{font:12px monospace;color:#a9b5a5;white-space:nowrap}
.lightbox svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.lightbox-close,.lightbox-nav{flex-shrink:0;display:grid;place-items:center;padding:0;border:1px solid #ffffff33;border-radius:50%;background:#ffffff0d;transition:background .2s}
.lightbox-close{width:46px;height:46px}
.lightbox-nav{width:54px;height:54px}
.lightbox-close:hover,.lightbox-nav:hover{background:#ffffff24}
.lightbox-nav[hidden]{display:grid;visibility:hidden}
html[dir=ltr] .lightbox-nav svg{transform:scaleX(-1)}
.lightbox-stage{position:relative;flex:1;min-height:0;display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:14px;padding:0 clamp(10px,2vw,26px) clamp(14px,2.5vh,26px)}
.lightbox-figure{margin:0;height:100%;min-height:0;min-width:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px}
.lightbox-media{flex:1;min-height:0;width:100%;display:flex;align-items:center;justify-content:center}
.lightbox-media img,.lightbox-media video{display:block;max-width:100%;max-height:100%;object-fit:contain;background:#000}
.lightbox-media video{width:min(100%,1180px);aspect-ratio:16/9;height:auto}
#lightbox-caption{font-size:13px;line-height:1.8;color:#cfd5c9;text-align:center;max-width:720px}

@media(max-width:1100px){
 .project-feature{grid-template-columns:1fr}
 .project-feature-copy{padding:30px 30px 34px}
}
@media(max-width:850px){
 .project-grid{grid-template-columns:1fr 1fr;gap:16px}
 .project-card:last-child{grid-column:1/-1}
 .project-card:last-child .project-card-media{aspect-ratio:16/9}
 .projects-cta{flex-direction:column;align-items:flex-start}
}
@media(max-width:600px){
 .partners-strip.client-showcase{padding-block:42px 46px}
 .client-showcase .partners-heading{margin-bottom:24px;gap:16px}
 .client-showcase .partners-heading h2{font-size:26px}
 .client-showcase .partners-heading{display:block}
 .client-showcase .partners-heading p{font-size:12px;margin-top:0;max-width:none}
 .client-showcase .partners-aside{margin-top:12px;justify-content:space-between}
 .marquee-toggle{width:40px;height:40px}
 .logo-marquee .client-logo{width:150px;height:86px;margin:5px;padding:12px 16px}
 .logo-marquee.is-animated .client-logo{margin:0 6px}
 .logo-marquee .client-logo img{width:112px;height:42px}
 .logo-marquee .logo-ksu img{height:40px}.logo-marquee .logo-kfsh img{height:46px}
 .logo-marquee .logo-othaimmall img,.logo-marquee .logo-panda img{height:56px}.logo-marquee .logo-aldrees img{height:48px}
 .logo-marquee .logo-autostar img{width:100px;height:48px}.logo-marquee .logo-aljomaih img{width:72px;height:48px}
 .logo-set{padding-inline:12px}
 .media-badge{top:10px;inset-inline-start:10px;font-size:10px;padding:5px 9px}
 .media-play{width:56px;height:56px}
 .project-feature-copy{padding:24px 20px 28px}
 .project-meta{gap:28px}
 .project-feature-copy>p{font-size:13px}
 .project-actions{flex-direction:column;align-items:stretch;gap:6px}
 .project-gallery-button{justify-content:space-between}
 .projects .project-actions .text-link{width:100%;justify-content:space-between}
 .project-thumbs{display:flex;overflow-x:auto;scroll-snap-type:x mandatory;gap:1px;scrollbar-width:none;overscroll-behavior-x:contain}
 .project-thumbs::-webkit-scrollbar{display:none}
 .project-thumbs li{flex:0 0 44%;scroll-snap-align:start}
 .project-grid{grid-template-columns:1fr;gap:14px;margin-top:14px}
 .project-card:last-child .project-card-media{aspect-ratio:16/10}
 .project-card-media{aspect-ratio:16/11}
 .project-card-body{padding:18px 20px 22px}
 .project-card-body h3{font-size:19px}
 .projects-cta{padding:22px 20px;margin-top:14px}
 .projects-cta>div>strong{font-size:18px}
 .projects-cta .contact-button{width:100%}
 .lightbox-bar{padding:10px 12px 8px}
 .lightbox-heading{flex-direction:column;gap:2px}
 .lightbox-heading strong{font-size:13px}
 .lightbox-stage{grid-template-columns:minmax(0,1fr);padding:0 0 calc(16px + env(safe-area-inset-bottom,0px))}
 .lightbox-nav{position:absolute;z-index:2;top:calc(50% - 40px);width:44px;height:44px;background:#0b1211b3}
 .lightbox-prev{inset-inline-start:8px}
 .lightbox-next{inset-inline-end:8px}
 #lightbox-caption{font-size:12px;padding-inline:16px}
}
@media(prefers-reduced-motion:reduce){
 .project-thumbs img,.project-card-media img,.media-play{transition:none}
 .project-feature-media.is-playing .live-dot{animation:none}
}
