/* Webzone — 3D effects, live demo devices, light theme */

/* ---------- fixed WebGL space behind the page ---------- */
.fx-space { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; transition: opacity .2s linear; }
body.has-space main, body.has-space .site-footer { position: relative; z-index: 1; }
body.has-space .hero::after { display: none; }
.hero { perspective: 1200px; }
.hero-content { transform-origin: 50% 0; will-change: transform, opacity; }

/* ---------- progress bar ---------- */
.fx-progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 200; background: var(--lime-fill, #B6FF00);
  transform-origin: 0 50%; transform: scaleX(0); box-shadow: 0 0 12px rgba(182,255,0,.7); pointer-events: none; }
[dir="rtl"] .fx-progress { transform-origin: 100% 50%; }

/* ---------- theme button ---------- */
.theme-btn { width: 40px; height: 40px; border-radius: 999px; border: 1px solid var(--line-2); background: transparent; color: var(--text);
  display: inline-grid; place-items: center; cursor: pointer; padding: 0; transition: border-color .2s, transform .3s; }
.theme-btn:hover { border-color: var(--lime); transform: rotate(-20deg); }
.theme-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.theme-btn .i-sun { display: none; }
[data-theme="light"] .theme-btn .i-sun { display: block; }
[data-theme="light"] .theme-btn .i-moon { display: none; }
.theme-anim, .theme-anim * { transition: background-color .45s ease, color .45s ease, border-color .45s ease !important; }

/* ---------- cursor light ---------- */
.fx-cursor { position: fixed; left: -260px; top: -260px; width: 520px; height: 520px; border-radius: 50%; pointer-events: none; z-index: 1;
  background: radial-gradient(circle, rgba(182,255,0,.09), rgba(182,255,0,0) 62%); opacity: 0; transition: opacity .4s; mix-blend-mode: screen; }
[data-theme="light"] .fx-cursor { mix-blend-mode: multiply; background: radial-gradient(circle, rgba(94,140,0,.10), rgba(94,140,0,0) 62%); }

/* ---------- 3D tilt cards ---------- */
.fx-tilt { transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s; transform-style: preserve-3d; will-change: transform; position: relative; }
.fx-tilt::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .3s;
  background: radial-gradient(400px circle at var(--gx, 50%) var(--gy, 50%), rgba(182,255,0,.10), transparent 45%); }
.fx-tilt:hover::after { opacity: 1; }
.btn-primary { transition: transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s; }

/* ---------- headings: words rise ---------- */
.fx-split { perspective: 600px; }
.fx-split .fx-w { display: inline-block; opacity: 0; transform: translateY(.6em) rotateX(-70deg); transform-origin: 50% 100%;
  transition: opacity .6s ease, transform .8s cubic-bezier(.2,.8,.2,1); }
.fx-split.fx-in .fx-w { opacity: 1; transform: none; }

/* ---------- marquee ---------- */
.fx-marquee { position: relative; z-index: 1; overflow: hidden; padding: 26px 0; border-block: 1px solid var(--line); white-space: nowrap;
  background: color-mix(in srgb, var(--bg) 80%, transparent); }
.fx-marquee-track { display: inline-flex; gap: 48px; will-change: transform; }
.fx-marquee span { font-family: var(--font-display); text-transform: uppercase; font-size: clamp(1.4rem, 3.4vw, 2.6rem); letter-spacing: .04em; color: transparent;
  -webkit-text-stroke: 1px var(--line-2); }
.fx-marquee span:nth-child(3n+1) { color: var(--text); -webkit-text-stroke: 0; }
.fx-marquee span.dot { color: var(--lime); -webkit-text-stroke: 0; }
html[lang="ar"] .fx-marquee span { font-family: var(--font-ar); }

/* ---------- live showcase: sticky 3D stage ---------- */
.showcase { position: relative; z-index: 1; height: 175vh; }
.sc-sticky { position: sticky; top: 0; height: 100vh; overflow: hidden; display: grid; grid-template-rows: auto 1fr; padding-top: clamp(84px, 10vh, 120px); }
.sc-head { text-align: center; transition: opacity .2s; }
.sc-head .h2 { margin-inline: auto; max-width: 860px; }
.sc-head .lead { margin-inline: auto; max-width: 640px; }
.sc-steps { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin: 18px 0 0; padding: 0; list-style: none; }
.sc-step { font-size: .85rem; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--muted); transition: all .35s; }
.sc-step.on { color: var(--bg); background: var(--lime-fill, #B6FF00); border-color: transparent; color: #0A0A0A; }
.sc-scene { perspective: 1600px; display: grid; place-items: center; }
.sc-stage { position: relative; width: min(1000px, 92vw); aspect-ratio: 16 / 9.6; transform-style: preserve-3d; will-change: transform; }

/* devices */
.dv { position: absolute; transform-style: preserve-3d; will-change: transform; }
.dv-screen { position: absolute; overflow: hidden; background: #111; }
.dv-screen iframe { position: absolute; top: 0; left: 0; border: 0; transform-origin: 0 0; pointer-events: none; background: #fff; opacity: 0; transition: opacity .6s; }
[dir="rtl"] .dv-screen iframe { left: 0; right: auto; }
.is-live iframe { opacity: 1; }
.dv-screen::before { /* loading shimmer */ content: ""; position: absolute; inset: 0;
  background: linear-gradient(110deg, #141414 30%, #1d1d1d 50%, #141414 70%); background-size: 200% 100%; animation: dvload 1.4s linear infinite; }
@keyframes dvload { to { background-position: -200% 0; } }
.dv-screen::after { /* glass reflection */ content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 2;
  background: linear-gradient(125deg, rgba(255,255,255,.10), rgba(255,255,255,0) 38%); }

/* laptop: screen 1280x800 scaled */
.dv-laptop { left: 14%; top: 4%; width: 72%; aspect-ratio: 16 / 10.6; }
.dv-laptop .dv-body { position: absolute; inset: 0; border-radius: 18px 18px 6px 6px; background: linear-gradient(#2a2a2a, #161616);
  box-shadow: 0 0 0 1px rgba(255,255,255,.08) inset, 0 60px 120px -40px rgba(0,0,0,.9), 0 0 80px -20px rgba(182,255,0,.18); }
.dv-laptop .dv-screen { inset: 3.2% 2.4% 5% 2.4%; border-radius: 6px; container-type: inline-size; }
.dv-laptop .dv-screen iframe { width: 1280px; height: 832px; transform: scale(calc(100cqw / 1280px)); }
.dv-laptop .dv-base { position: absolute; left: -9%; right: -9%; bottom: -4.6%; height: 5%; border-radius: 0 0 22px 22px;
  background: linear-gradient(#3a3a3a, #1a1a1a); box-shadow: 0 30px 50px -20px rgba(0,0,0,.9); transform: translateZ(10px); }
.dv-laptop .dv-base::before { content: ""; position: absolute; left: 42%; right: 42%; top: 0; height: 30%; border-radius: 0 0 8px 8px; background: #111; }

/* phones */
.dv-phone { width: 19%; aspect-ratio: 9 / 19.2; }
.dv-phone .dv-body { position: absolute; inset: 0; border-radius: 16% / 7.6%; background: linear-gradient(145deg, #2c2c2c, #0f0f0f);
  box-shadow: 0 0 0 1px rgba(255,255,255,.1) inset, 0 40px 90px -30px rgba(0,0,0,.95), 0 0 60px -20px rgba(182,255,0,.22); }
.dv-phone .dv-screen { inset: 2.6% 4.6%; border-radius: 12% / 5.6%; container-type: inline-size; }
.dv-phone .dv-screen iframe { width: 390px; height: 844px; transform: scale(calc(100cqw / 390px)); }
.dv-phone .dv-notch { position: absolute; z-index: 3; top: 4.2%; left: 50%; width: 30%; height: 3.4%; transform: translateX(-50%); border-radius: 99px; background: #050505; }
.dv-p1 { left: 0; top: 30%; }
.dv-p2 { right: 0; top: 24%; }
/* tablet */
.dv-tablet { width: 30%; aspect-ratio: 3 / 4; left: 35%; top: 52%; display: none; }

[dir="rtl"] .dv-p1 { left: auto; right: 0; }
[dir="rtl"] .dv-p2 { right: auto; left: 0; }

.sc-note { position: absolute; bottom: 22px; left: 0; right: 0; text-align: center; font-size: .8rem; color: var(--muted); }

@media (max-width: 760px) {
  .showcase { height: 165vh; }
  .sc-stage { width: 94vw; aspect-ratio: 3 / 4; }
  .dv-laptop { left: 2%; top: 0; width: 96%; }
  .dv-phone { width: 40%; }
  .dv-phone { width: 36%; }
  .dv-p1 { top: 30%; left: 6%; }
  .dv-p2 { top: 24%; right: 6%; }
  .sc-note { bottom: 10px; }
  .sc-steps { display: none; }
}

/* ---------- wall of live demos ---------- */
.wall { position: relative; z-index: 1; height: 100vh; overflow: hidden; perspective: 1400px; margin-top: clamp(140px, 22vh, 240px); border-top: 1px solid var(--line); }
.wall-inner { position: absolute; left: 50%; top: 50%; width: 1500px; display: flex; gap: 28px; justify-content: center;
  transform: translate(-50%, -50%) rotateX(38deg) rotateZ(-14deg) scale(.95); transform-style: preserve-3d; }
[dir="rtl"] .wall-inner { transform: translate(-50%, -50%) rotateX(38deg) rotateZ(14deg) scale(.95); }
.wall-col { display: flex; flex-direction: column; gap: 28px; will-change: transform; }
.wall .dv-card { position: relative; width: 300px; aspect-ratio: 9 / 16; border-radius: 22px; overflow: hidden; background: #111;
  box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 40px 70px -30px rgba(0,0,0,.9); }
.wall .dv-card .dv-screen { inset: 0; container-type: inline-size; }
.wall .dv-card .dv-screen iframe { width: 390px; height: 694px; transform: scale(calc(100cqw / 390px)); }
.wall-fade { position: absolute; inset: 0; pointer-events: none; z-index: 2;
  background: linear-gradient(var(--bg), transparent 22%, transparent 70%, var(--bg)), radial-gradient(ellipse at center, transparent 40%, var(--bg) 92%); }
.wall-title { position: absolute; z-index: 3; inset: 0; display: grid; place-items: center; text-align: center; pointer-events: none; padding: 0 var(--pad); }
.wall-title .h2 { font-size: clamp(2rem, 6vw, 4.6rem); text-shadow: 0 10px 40px var(--bg), 0 0 80px var(--bg); }
.wall-title p { margin-top: 14px; color: var(--muted); text-shadow: 0 2px 20px var(--bg); }
@media (max-width: 760px) { .wall { height: 82vh; margin-top: 110px; } .wall-col:nth-child(n+4) { display: none; } .wall-inner { width: 1000px; gap: 16px; } .wall .dv-card { width: 200px; } .wall-col { gap: 16px; } }

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .showcase { height: auto; } .sc-sticky { position: relative; height: auto; padding-bottom: 60px; }
  .sc-stage { transform: none !important; }
  .fx-split .fx-w { opacity: 1; transform: none; }
}

/* ================= LIGHT THEME ================= */
[data-theme="light"] {
  --bg: #F5F7FA; --bg-2: #FFFFFF; --card: #FFFFFF;
  --line: rgba(10,10,10,.09); --line-2: rgba(10,10,10,.18);
  --text: #0A0A0A; --muted: #55595F; --grey: #6b6f75;
  --lime: #5E8C00; --lime-soft: rgba(94,140,0,.10); --lime-fill: #B6FF00;
  color-scheme: light;
}
[data-theme="light"] body { background: var(--bg); color: var(--text); }
[data-theme="light"] .site-header { background: rgba(245,247,250,.78); }
[data-theme="light"] .btn-primary, [data-theme="light"] .skip, [data-theme="light"] .nav a.btn,
[data-theme="light"] .eyebrow::before, [data-theme="light"] .badge, [data-theme="light"] ::selection { background: #B6FF00; color: #0A0A0A; }
[data-theme="light"] .btn-primary:hover { color: #0A0A0A; box-shadow: 0 10px 30px -10px rgba(94,140,0,.55); }
[data-theme="light"] .eyebrow::before { box-shadow: 0 0 10px rgba(94,140,0,.6); }
[data-theme="light"] .btn-ghost { background: rgba(10,10,10,.02); }
[data-theme="light"] .nav a:hover { background: rgba(10,10,10,.05); }
[data-theme="light"] .hero-points { color: #3c3f44; }
[data-theme="light"] .fx-marquee { background: color-mix(in srgb, var(--bg) 75%, transparent); }
[data-theme="light"] .dv-laptop .dv-body, [data-theme="light"] .dv-phone .dv-body { box-shadow: 0 0 0 1px rgba(255,255,255,.08) inset, 0 50px 90px -40px rgba(10,10,10,.5); }
[data-theme="light"] .wall .dv-card { box-shadow: 0 0 0 1px rgba(10,10,10,.08), 0 40px 70px -30px rgba(10,10,10,.45); }
[data-theme="light"] .fx-progress { box-shadow: none; }

/* wall title readable over the bright demo screens */
.wall-title > div { background: color-mix(in srgb, var(--bg) 88%, transparent);
  padding: clamp(20px, 3vw, 34px) clamp(24px, 4vw, 48px); border-radius: 28px; border: 1px solid var(--line-2); box-shadow: 0 30px 80px -30px rgba(0,0,0,.7); }
.wall-title .h2 { text-shadow: none; }
.wall-title p { text-shadow: none; }

/* light theme: logo + text colours that were hard-coded for dark */
.logo-light { display: none; }
[data-theme="light"] .logo-dark { display: none; }
[data-theme="light"] .logo-light { display: block; }
[data-theme="light"] .nav a { color: #3c3f44; }
[data-theme="light"] .nav a:hover, [data-theme="light"] .nav a[aria-current="page"] { color: var(--text); }
[data-theme="light"] .lead, [data-theme="light"] .faq .answer, [data-theme="light"] .cta-band p,
[data-theme="light"] .disclaimer, [data-theme="light"] .prose, [data-theme="light"] blockquote { color: #4a4e54; }
[data-theme="light"] .checks li, [data-theme="light"] .tags li, [data-theme="light"] .site-footer a, [data-theme="light"] .field label { color: #2b2e33; }
[data-theme="light"] .card, [data-theme="light"] .price-card { background: linear-gradient(180deg, #FFFFFF, #F9FAFB); box-shadow: 0 20px 50px -30px rgba(10,10,10,.25); }
[data-theme="light"] .price-card.featured { background: linear-gradient(180deg, rgba(182,255,0,.16), #FFFFFF 45%); border-color: #5E8C00; }
[data-theme="light"] .cta-band { background: linear-gradient(135deg, rgba(182,255,0,.18), #FFFFFF 55%); }
[data-theme="light"] .field input, [data-theme="light"] .field textarea { background: #FFFFFF; color: #0A0A0A; }
[data-theme="light"] .field input::placeholder, [data-theme="light"] .field textarea::placeholder { color: #8a8e94; }
[data-theme="light"] .site-footer { background: #ECEFF3; }
[data-theme="light"] .wall-title > div { box-shadow: 0 30px 80px -30px rgba(10,10,10,.25); }

/* performance: no shimmer once the demo is loaded */
.is-live .dv-screen::before { animation: none; display: none; }

/* phones: lighter rendering (no blur behind the header, no 3D tilt on the wall) */
@media (max-width: 760px), (hover: none) {
  .site-header { -webkit-backdrop-filter: none !important; backdrop-filter: none !important; background: color-mix(in srgb, var(--bg) 94%, transparent) !important; }
  .dv-body, .wall .dv-card { box-shadow: 0 20px 40px -20px rgba(0,0,0,.8) !important; }
}

/* WhatsApp floating button */
.wa-fab { position: fixed; z-index: 60; bottom: 20px; inset-inline-end: 20px; width: 58px; height: 58px; border-radius: 50%;
  display: grid; place-items: center; background: #B6FF00; color: #0A0A0A; box-shadow: 0 12px 30px -8px rgba(0,0,0,.6);
  transition: transform .2s; }
.wa-fab:hover { transform: scale(1.08); }
.wa-fab svg { width: 30px; height: 30px; fill: currentColor; }
.wa-fab[hidden] { display: none; }
@media (max-width: 760px) { .wa-fab { width: 52px; height: 52px; bottom: 14px; inset-inline-end: 14px; } }
