:root {
  --bg: #0d0d1f;
  --bg-2: #14142e;
  --card: #1a1a35;
  --card-2: #20204a;
  --border: rgba(255,255,255,0.08);
  --text: #f0f0f7;
  --text-dim: #a9a9c5;
  --primary: #7c3aed;
  --primary-2: #a855f7;
  --accent: #06b6d4;
  --success: #22c55e;
  --gradient: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 50%, var(--accent) 100%);
  --shadow: 0 20px 60px rgba(0,0,0,0.45);
  --radius: 18px;
  --font-ar: 'Cairo', system-ui, sans-serif;
  --font-en: 'Poppins', system-ui, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-ar);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
  transition: font-family .3s;
}

/* LTR mode */
html[lang="en"] body { font-family: var(--font-en); }
html[lang="en"] .hero-title .gradient-text,
html[lang="en"] .brand-accent { letter-spacing: 0; text-transform: none; }

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(60% 50% at 20% 0%, rgba(124,58,237,0.18), transparent 60%),
    radial-gradient(50% 40% at 90% 10%, rgba(6,182,212,0.12), transparent 60%),
    var(--bg);
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  opacity: .35;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

.container { width: min(1140px, 92%); margin: 0 auto; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  border-radius: 14px;
  text-decoration: none;
  transition: transform .2s, box-shadow .2s, background .2s;
  font-family: inherit;
}
.btn:hover { transform: translateY(-3px); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--gradient); color: #fff; box-shadow: 0 10px 30px rgba(124,58,237,0.4); }
.btn-primary:hover { box-shadow: 0 15px 40px rgba(124,58,237,0.6); }
.btn-ghost { background: transparent; color: var(--text); border: 2px solid var(--border); }
.btn-ghost:hover { border-color: var(--primary); }
.btn-success { background: linear-gradient(135deg, #22c55e, #16a34a); color: #fff; box-shadow: 0 10px 30px rgba(34,197,94,0.4); }
.btn-success:hover { box-shadow: 0 15px 40px rgba(34,197,94,0.55); }
.btn-play { background: linear-gradient(135deg, #34a853, #1e9e4a); color: #fff; box-shadow: 0 10px 30px rgba(52,168,83,0.4); }
.btn-play:hover { box-shadow: 0 15px 40px rgba(52,168,83,0.55); }
.btn-lg { padding: 16px 34px; font-size: 1.05rem; }
.btn-xl { padding: 19px 42px; font-size: 1.2rem; }
.btn-sm { padding: 9px 20px; font-size: .85rem; }

/* ===== Navbar ===== */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 16px 0;
  transition: background .3s, box-shadow .3s, padding .3s;
}
.navbar.scrolled {
  background: rgba(13,13,31,0.85);
  backdrop-filter: blur(14px);
  box-shadow: 0 4px 30px rgba(0,0,0,0.4);
  padding: 10px 0;
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; }

.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand-icon { width: 38px; height: 38px; border-radius: 10px; object-fit: cover; }
.brand-name { font-weight: 800; font-size: 1.15rem; }
.brand-accent { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }

.nav-links { display: flex; gap: 30px; }
.nav-links a { color: var(--text-dim); text-decoration: none; font-weight: 600; font-size: .95rem; transition: color .2s; }
.nav-links a:hover { color: var(--primary-2); }

.nav-actions { display: flex; align-items: center; gap: 14px; }
.lang-toggle {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--card); color: var(--text);
  border: 1px solid var(--border); border-radius: 30px;
  padding: 8px 16px; cursor: pointer; font-family: inherit; font-weight: 700; font-size: .85rem;
  transition: background .2s;
}
.lang-toggle:hover { background: var(--card-2); }
.lang-current { color: var(--accent); font-size: .85rem; letter-spacing: 1px; }

.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px; }
.hamburger span { display: block; width: 24px; height: 2.5px; background: var(--text); border-radius: 2px; }

/* ===== Hero ===== */
.hero { position: relative; min-height: 100vh; display: flex; align-items: center; padding: 120px 0 80px; }
.hero-bg {
  position: absolute; inset: 0;
  background:
    radial-gradient(40% 50% at 80% 30%, rgba(124,58,237,0.25), transparent 60%),
    radial-gradient(30% 40% at 20% 60%, rgba(6,182,212,0.15), transparent 60%);
  z-index: -1;
}
.hero-inner { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 60px; align-items: center; }

.badge {
  display: inline-block; background: rgba(124,58,237,0.15); color: var(--primary-2);
  border: 1px solid rgba(124,58,237,0.4); padding: 6px 14px; border-radius: 30px;
  font-size: .8rem; font-weight: 700; margin-bottom: 18px; letter-spacing: .5px;
}
.hero-title { font-size: clamp(2.6rem, 6vw, 4.2rem); font-weight: 900; line-height: 1.1; margin-bottom: 20px; }
.gradient-text { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-subtitle { font-size: 1.1rem; color: var(--text-dim); margin-bottom: 32px; max-width: 540px; }
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 44px; }

.hero-stats { display: flex; gap: 40px; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; }
.stat-num { font-size: 1.9rem; font-weight: 900; color: var(--text); }
.stat-label { color: var(--text-dim); font-size: .85rem; }

.hero-visual { position: relative; display: flex; justify-content: center; }
.tv-visual { position: relative; display: flex; flex-direction: column; align-items: center; }
.tv-frame {
  width: 480px; aspect-ratio: 16/9;
  background: #111; border-radius: 18px; overflow: hidden;
  box-shadow: var(--shadow), 0 0 70px rgba(124,58,237,0.35);
  border: 4px solid #222;
  position: relative;
}
.tv-screen-wrap { position: absolute; inset: 8px; border-radius: 6px; overflow: hidden; background: #000; }
.tv-screen { width: 100%; height: 100%; object-fit: cover; display: block; }
.tv-brand {
  position: absolute; bottom: 12px; right: 18px; z-index: 2;
  color: #fff; font-size: .75rem; letter-spacing: 1px; opacity: .0;
  text-shadow: 0 1px 4px rgba(0,0,0,0.6);
}
.tv-stand {
  width: 180px; position: relative;
  display: flex; flex-direction: column; align-items: center; margin-top: -4px;
}
.tv-neck { width: 22px; height: 34px; background: linear-gradient(#2a2a2a, #111); }
.tv-base {
  width: 180px; height: 18px; border-radius: 6px;
  background: linear-gradient(#3a3a3a, #1a1a1a);
  box-shadow: 0 10px 20px rgba(0,0,0,0.5);
}

.float-badge {
  position: absolute; background: rgba(20,20,46,0.95); border: 1px solid var(--border);
  backdrop-filter: blur(10px); padding: 10px 16px; border-radius: 14px; font-weight: 700; font-size: .9rem;
  box-shadow: var(--shadow); animation: float 4s ease-in-out infinite;
}
.float-badge-1 { top: 15%; right: -10px; color: var(--accent); }
.float-badge-2 { bottom: 20%; left: -10px; color: #fff; animation-delay: 1.5s; }

@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-14px)} }

.scroll-hint { position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%); }
.mouse { display: block; width: 26px; height: 42px; border: 2px solid var(--text-dim); border-radius: 20px; position: relative; }
.mouse::after { content:""; position: absolute; top: 8px; left: 50%; transform: translateX(-50%); width: 4px; height: 8px; background: var(--text-dim); border-radius: 4px; animation: wheel 1.6s infinite; }
@keyframes wheel { 0%{opacity:1;top:8px} 100%{opacity:0;top:22px} }

/* ===== Sections ===== */
.section { padding: 90px 0; }
.section-dark { background: rgba(26,26,53,0.5); }
.section-head { text-align: center; max-width: 700px; margin: 0 auto 56px; }
.section-tag { display: inline-block; color: var(--accent); font-weight: 700; font-size: .85rem; letter-spacing: 2px; text-transform: uppercase; margin-bottom: 12px; }
.section-title { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 900; margin-bottom: 14px; }
.section-desc { color: var(--text-dim); font-size: 1.05rem; }

/* Features */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.feature-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 34px 28px; transition: transform .25s, border-color .25s, background .25s;
}
.feature-card:hover { transform: translateY(-6px); border-color: rgba(124,58,237,0.5); background: var(--card-2); }
.feature-icon { font-size: 2.4rem; margin-bottom: 16px; }
.feature-card h3 { font-size: 1.2rem; font-weight: 800; margin-bottom: 10px; }
.feature-card p { color: var(--text-dim); font-size: .93rem; }

/* Screens slider gallery */
.gallery-slider { position: relative; max-width: 920px; margin: 0 auto; }
.gallery-stage {
  position: relative; width: 100%; height: 460px; overflow: hidden;
  border-radius: 20px; border: 1px solid var(--border); box-shadow: var(--shadow);
  background: #000;
}
.slide { position: absolute; inset: 0; margin: 0; display: flex; flex-direction: column; opacity: 0; visibility: hidden; transition: opacity .5s ease, transform .5s ease; transform: scale(.97); }
.slide.active { opacity: 1; visibility: visible; transform: scale(1); position: relative; }
.slide-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.slide-tall { object-fit: contain; background: #0d0d1f; padding: 14px; }
.slide-wide { object-fit: contain; background: #0d0d1f; }
.slide figcaption {
  position: absolute; bottom: 0; left: 0; right: 0; padding: 34px 24px 16px;
  background: linear-gradient(transparent, rgba(0,0,0,0.85)); color: #fff;
  font-weight: 700; font-size: 1rem; text-align: center;
}
.gal-btn {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 5;
  width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--border);
  background: rgba(13,13,31,0.8); color: var(--text); font-size: 1.6rem; line-height: 1;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: background .2s, transform .2s; backdrop-filter: blur(6px);
}
.gal-btn:hover { background: var(--primary); }
.gal-prev { left: 10px; }
.gal-next { right: 10px; }
.gal-dots { display: flex; justify-content: center; gap: 8px; margin-top: 18px; }
.gal-dots button {
  width: 10px; height: 10px; border-radius: 50%; border: none; cursor: pointer;
  background: rgba(255,255,255,0.25); transition: background .2s, width .2s;
}
.gal-dots button.active { background: var(--primary-2); width: 26px; border-radius: 6px; }

/* Download */
.download-card {
  background: var(--gradient); border-radius: 28px; padding: 56px;
  display: grid; grid-template-columns: 1.3fr 0.7fr; gap: 40px; align-items: center;
  box-shadow: 0 30px 80px rgba(124,58,237,0.35); position: relative; overflow: hidden;
}
.download-card::before {
  content: ""; position: absolute; inset: 0;
  background: rgba(0,0,0,0.2);
}
.download-content { position: relative; z-index: 1; }
.download-card .section-tag { color: rgba(255,255,255,0.8); }
.download-card .section-title { color: #fff; }
.download-desc { color: rgba(255,255,255,0.85); margin-bottom: 24px; }
.download-meta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 28px; }
.meta-chip { background: rgba(255,255,255,0.15); border: 1px solid rgba(255,255,255,0.25); padding: 8px 14px; border-radius: 10px; font-size: .85rem; backdrop-filter: blur(4px); }
.meta-chip b { font-weight: 800; }
.download-ver { color: rgba(255,255,255,0.7); font-size: .82rem; margin-top: 16px; }
.btn-dl-icon { font-size: 1.1rem; }
.download-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.download-art { display: flex; justify-content: center; position: relative; z-index: 1; }
.qr-placeholder {
  background: #fff; color: #111; border-radius: 20px; padding: 24px;
  display: flex; flex-direction: column; align-items: center; gap: 10px; box-shadow: var(--shadow);
  font-weight: 800; text-align: center; transform: rotate(3deg);
}
.qr-icon { width: 90px; height: 90px; border-radius: 14px; object-fit: cover; }

/* FAQ */
.faq-list { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.faq-item { background: var(--card); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.faq-q {
  width: 100%; background: none; border: none; color: var(--text);
  font-family: inherit; font-size: 1.05rem; font-weight: 700; text-align: left;
  padding: 20px 24px; cursor: pointer; display: flex; justify-content: space-between; align-items: center;
}
.faq-q::after { content: "+"; font-size: 1.5rem; color: var(--accent); transition: transform .3s; }
.faq-item.open .faq-q::after { transform: rotate(45deg); }
.faq-a {
  max-height: 0; overflow: hidden; transition: max-height .35s ease, padding .35s;
  color: var(--text-dim); padding: 0 24px; font-size: .95rem;
}
.faq-item.open .faq-a { max-height: 240px; padding: 0 24px 20px; }

html[lang="en"] .faq-q { text-align: left; }

/* ===== Footer ===== */
.footer { padding: 50px 0; border-top: 1px solid var(--border); background: rgba(13,13,31,0.9); }
.footer-inner { text-align: center; position: relative; }
.footer-brand { display: flex; align-items: center; justify-content: center; gap: 10px; font-weight: 800; font-size: 1.2rem; margin-bottom: 16px; }
.footer-icon { width: 30px; height: 30px; border-radius: 8px; }
.footer-copy { color: var(--text-dim); font-size: .9rem; margin-bottom: 8px; }
.footer-legal { color: var(--text-dim); font-size: .78rem; max-width: 620px; margin: 0 auto; opacity: .8; }
.back-top {
  position: absolute; top: 0; right: 0; width: 44px; height: 44px;
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  color: var(--text); display: flex; align-items: center; justify-content: center; text-decoration: none;
  font-size: 1.2rem; transition: background .2s, transform .2s;
}
.back-top:hover { background: var(--primary); transform: translateY(-4px); }

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; gap: 50px; }
  .hero-subtitle { margin-left: auto; margin-right: auto; }
  .hero-cta, .hero-stats { justify-content: center; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-stage { height: 360px; }
  .download-card { grid-template-columns: 1fr; text-align: center; padding: 40px 28px; }
  .download-meta { justify-content: center; }
  .nav-links {
    position: fixed; top: 0; right: -100%; width: 70%; height: 100vh;
    background: var(--bg-2); flex-direction: column; justify-content: center; align-items: center;
    gap: 30px; transition: right .35s; box-shadow: -10px 0 40px rgba(0,0,0,0.5);
  }
  html[lang="en"] .nav-links { right: auto; left: -100%; }
  html[lang="en"] .nav-links.open { left: 0; }
  .nav-links.open { right: 0; }
  .hamburger { display: flex; }
}
@media (max-width: 600px) {
  .tv-frame { width: 320px; }
  .tv-stand { width: 140px; }
  .tv-base { width: 140px; }
  .features-grid { grid-template-columns: 1fr; }
  .gallery-stage { height: 260px; }
  .nav-download { display: none; }
  .section { padding: 64px 0; }
  .back-top { display: none; }
}
