/* ═══════════ Design tokens ═══════════ */
:root {
    --navy-950: #070c1a;
    --navy-900: #0b1226;
    --navy-800: #111a30;
    --navy-700: #1b2540;
    --blue-700: #1d3fc6;
    --blue-600: #2f63f2;
    --blue-400: #84acff;
    --ink: #0f172a;
    --ink-soft: #47536b;
    --paper: #f7f9fd;
    --white: #ffffff;
    --line: rgba(15, 23, 42, 0.08);
    --line-dark: rgba(132, 172, 255, 0.14);
    --radius: 16px;
    --font-en: "Outfit", system-ui, sans-serif;
    --font-ar: "Cairo", system-ui, sans-serif;
    --shadow-lg: 0 24px 60px -18px rgba(11, 18, 38, 0.35);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-en);
    color: var(--ink);
    background: var(--white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
html[lang="ar"] body { font-family: var(--font-ar); }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
.container { max-width: 1120px; margin-inline: auto; padding-inline: 24px; }

/* ═══════════ Reveal animations ═══════════ */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.7, 0.3, 1); }
.reveal.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal { opacity: 1; transform: none; transition: none; }
    .pulse-path, .orb, .progress-fill, .badge-dot { animation: none !important; }
}

/* ═══════════ Buttons ═══════════ */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font-weight: 600; border-radius: 12px; border: none; cursor: pointer;
    font-family: inherit; font-size: 15px; padding: 12px 22px;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, opacity 0.18s ease;
    white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
    background: linear-gradient(135deg, var(--blue-700), var(--blue-600));
    color: #fff; box-shadow: 0 10px 26px -10px rgba(47, 99, 242, 0.65);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 32px -10px rgba(47, 99, 242, 0.75); }
.btn-outline { background: rgba(132, 172, 255, 0.08); color: #dbe6ff; border: 1px solid rgba(132, 172, 255, 0.35); }
.btn-outline:hover { background: rgba(132, 172, 255, 0.16); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: inherit; padding: 10px 14px; }
.btn-ghost:hover { opacity: 0.75; }
.btn-sm { padding: 9px 16px; font-size: 14px; }
.btn-lg { padding: 15px 30px; font-size: 16px; }
.btn-block { width: 100%; }

/* ═══════════ Nav ═══════════ */
.nav {
    position: fixed; inset-inline: 0; top: 0; z-index: 60;
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    background: rgba(7, 12, 26, 0.72);
    border-bottom: 1px solid var(--line-dark);
    color: #e6ecfb;
}
.nav-inner { display: flex; align-items: center; gap: 28px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; }
.brand img { border-radius: 9px; }
.nav-links { display: flex; gap: 24px; font-size: 14.5px; font-weight: 500; margin-inline-start: 12px; }
.nav-links a { opacity: 0.82; transition: opacity 0.15s; }
.nav-links a:hover { opacity: 1; }
.nav-actions { margin-inline-start: auto; display: flex; align-items: center; gap: 10px; }
.lang-toggle {
    background: rgba(132, 172, 255, 0.1); color: #cfdcff;
    border: 1px solid rgba(132, 172, 255, 0.3); border-radius: 10px;
    padding: 7px 14px; font-size: 13.5px; font-weight: 600; cursor: pointer;
    font-family: var(--font-ar); transition: background 0.15s;
}
html[lang="ar"] .lang-toggle { font-family: var(--font-en); }
.lang-toggle:hover { background: rgba(132, 172, 255, 0.2); }

@media (max-width: 760px) {
    .nav-links { display: none; }
}
@media (max-width: 480px) {
    .nav-inner { gap: 10px; height: 58px; padding-inline: 0; }
    .nav .container { padding-inline: 14px; }
    .brand { font-size: 15px; gap: 7px; }
    .brand img { width: 27px; height: 27px; }
    .nav-actions { gap: 7px; }
    .lang-toggle { padding: 6px 10px; font-size: 12px; }
    .nav .btn-sm { padding: 8px 11px; font-size: 12.5px; }
}
@media (max-width: 350px) {
    .brand-name { display: none; }
}

/* ═══════════ Hero ═══════════ */
.hero {
    position: relative; overflow: hidden;
    background: radial-gradient(120% 90% at 50% 0%, var(--navy-800) 0%, var(--navy-950) 62%);
    color: #eef2fc; padding: 150px 0 90px; text-align: center;
}
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.orb { position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.5; animation: float 9s ease-in-out infinite alternate; }
.orb-1 { width: 480px; height: 480px; background: rgba(47, 99, 242, 0.35); top: -180px; inset-inline-start: -120px; }
.orb-2 { width: 380px; height: 380px; background: rgba(29, 63, 198, 0.3); bottom: -140px; inset-inline-end: -100px; animation-delay: -4s; }
.orb-3 { width: 460px; height: 460px; background: rgba(47, 99, 242, 0.28); top: -160px; inset-inline-end: -140px; }
@keyframes float { from { transform: translateY(0) } to { transform: translateY(34px) } }

.grid-overlay {
    position: absolute; inset: 0;
    background-image: linear-gradient(rgba(132,172,255,0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(132,172,255,0.05) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: radial-gradient(70% 60% at 50% 30%, #000 30%, transparent 100%);
    -webkit-mask-image: radial-gradient(70% 60% at 50% 30%, #000 30%, transparent 100%);
}

.hero-inner { position: relative; }
.hero-badge {
    display: inline-flex; align-items: center; gap: 9px;
    background: rgba(132, 172, 255, 0.09); border: 1px solid rgba(132, 172, 255, 0.25);
    border-radius: 999px; padding: 7px 18px; font-size: 13.5px; font-weight: 500; color: #c6d6ff;
    margin-bottom: 26px;
}
.badge-dot { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; animation: blink 2.2s ease-in-out infinite; }
@keyframes blink { 0%,100% { opacity: 1 } 50% { opacity: 0.35 } }

.hero-title { font-size: clamp(38px, 6.4vw, 68px); font-weight: 800; line-height: 1.08; letter-spacing: -0.02em; }
html[lang="ar"] .hero-title { letter-spacing: 0; line-height: 1.28; }
.accent {
    background: linear-gradient(100deg, var(--blue-400), var(--blue-600));
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub { max-width: 620px; margin: 22px auto 0; font-size: clamp(16px, 2.2vw, 19px); color: #aebadb; font-weight: 300; }
.hero-ctas { display: flex; gap: 14px; justify-content: center; margin-top: 34px; flex-wrap: wrap; }

.pulse-line { width: min(600px, 88%); margin: 44px auto 0; display: block; }
.pulse-path { stroke-dasharray: 900; stroke-dashoffset: 900; animation: drawPulse 3.4s ease-out infinite; }
@keyframes drawPulse { 0% { stroke-dashoffset: 900 } 55% { stroke-dashoffset: 0 } 100% { stroke-dashoffset: -900 } }

/* ═══════════ Product mockup ═══════════ */
.mockup {
    margin: 26px auto 0; max-width: 860px; border-radius: 18px; overflow: hidden;
    border: 1px solid var(--line-dark); background: var(--navy-900);
    box-shadow: var(--shadow-lg); text-align: start;
    transition-delay: 0.15s;
}
.mockup-titlebar {
    display: flex; align-items: center; gap: 7px; padding: 12px 16px;
    background: var(--navy-800); border-bottom: 1px solid var(--line-dark);
}
.tb-dot { width: 10px; height: 10px; border-radius: 50%; background: #2c3a5e; }
.tb-url {
    margin-inline: auto; font-size: 12px; color: #7385ad; background: rgba(132,172,255,0.07);
    padding: 3px 26px; border-radius: 7px; direction: ltr;
}
.mockup-body { display: flex; min-height: 320px; }
.mockup-side {
    width: 64px; border-inline-end: 1px solid var(--line-dark); padding: 16px 0;
    display: flex; flex-direction: column; align-items: center; gap: 14px; background: rgba(11, 18, 38, 0.6);
}
.ms-logo { margin-bottom: 8px; }
.ms-logo img { border-radius: 6px; }
.ms-item { width: 26px; height: 26px; border-radius: 8px; background: rgba(132,172,255,0.1); }
.ms-item.active { background: rgba(47, 99, 242, 0.5); }
.mockup-main { flex: 1; padding: 22px; }
.mm-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.stat-card {
    background: rgba(132, 172, 255, 0.06); border: 1px solid var(--line-dark);
    border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 2px;
}
.stat-num { font-size: 24px; font-weight: 700; color: #eef2fc; font-variant-numeric: tabular-nums; }
.stat-num.accent { color: var(--blue-400); background: none; -webkit-text-fill-color: currentColor; }
.stat-label { font-size: 11.5px; color: #7385ad; }
.mm-rows { margin-top: 16px; display: flex; flex-direction: column; gap: 10px; }
.task-row {
    display: flex; align-items: center; gap: 12px; padding: 11px 14px;
    background: rgba(132, 172, 255, 0.05); border: 1px solid var(--line-dark); border-radius: 10px;
}
.task-check { width: 16px; height: 16px; border-radius: 5px; border: 1.5px solid #3d4f7d; flex-shrink: 0; }
.task-check.done { background: var(--blue-600); border-color: var(--blue-600); }
.task-bar { height: 8px; border-radius: 5px; background: #2a3757; }
.w-45 { width: 45%; } .w-55 { width: 55%; } .w-60 { width: 60%; } .w-70 { width: 70%; } .w-80 { width: 80%; }
.pill {
    margin-inline-start: auto; font-size: 11px; font-weight: 600; padding: 3px 11px;
    border-radius: 999px; white-space: nowrap; flex-shrink: 0;
}
.pill-green { background: rgba(74, 222, 128, 0.13); color: #4ade80; }
.pill-blue { background: rgba(132, 172, 255, 0.14); color: #84acff; }
.pill-amber { background: rgba(251, 191, 36, 0.13); color: #fbbf24; }
.pill-violet { background: rgba(167, 139, 250, 0.14); color: #7c5cf0; }
.progress-block { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.progress-track { height: 7px; border-radius: 5px; background: #1c2846; overflow: hidden; }
.progress-fill {
    height: 100%; width: 0; border-radius: 5px;
    background: linear-gradient(90deg, var(--blue-700), var(--blue-400));
    transition: width 1.4s cubic-bezier(0.25, 0.8, 0.3, 1);
}
.mockup.visible .progress-fill { width: var(--w); }

@media (max-width: 640px) {
    .mm-stats { grid-template-columns: repeat(2, 1fr); }
    .mockup-side { display: none; }
}

/* ═══════════ Sections (light) ═══════════ */
.section-title { font-size: clamp(28px, 4.2vw, 42px); font-weight: 800; letter-spacing: -0.015em; line-height: 1.16; }
html[lang="ar"] .section-title { letter-spacing: 0; line-height: 1.35; }
.section-sub { color: var(--ink-soft); font-size: 17px; margin-top: 12px; max-width: 560px; }

.pain { padding: 96px 0; background: var(--paper); text-align: center; }
.pain .section-sub { margin-inline: auto; }
.pain-flow { display: flex; align-items: center; justify-content: center; gap: 26px; margin-top: 44px; flex-wrap: wrap; }
.pain-chips { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.chip {
    background: #fff; border: 1px solid var(--line); border-radius: 12px;
    padding: 12px 18px; font-size: 14.5px; font-weight: 500; color: var(--ink-soft);
    box-shadow: 0 4px 14px -6px rgba(15, 23, 42, 0.08);
}
.flow-arrow { font-size: 26px; color: var(--blue-600); font-weight: 700; }
html[dir="rtl"] .flow-arrow { transform: scaleX(-1); }
.pain-result {
    display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 16px;
    background: linear-gradient(135deg, var(--navy-800), var(--navy-950));
    color: #fff; padding: 14px 24px; border-radius: 14px;
    box-shadow: 0 14px 30px -12px rgba(11, 18, 38, 0.45);
}
.pain-result img { border-radius: 7px; }

.features { padding: 100px 0; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 48px; }
.feature-card {
    background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
    padding: 28px 26px; transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s;
}
.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 22px 44px -16px rgba(15, 23, 42, 0.16);
    border-color: rgba(47, 99, 242, 0.35);
}
.fc-icon {
    width: 48px; height: 48px; display: flex; align-items: center; justify-content: center;
    font-size: 23px; border-radius: 13px; margin-bottom: 18px;
    background: linear-gradient(135deg, rgba(47, 99, 242, 0.1), rgba(132, 172, 255, 0.14));
    border: 1px solid rgba(47, 99, 242, 0.15);
}
.feature-card h3 { font-size: 17.5px; font-weight: 700; margin-bottom: 8px; }
.feature-card p { font-size: 14.5px; color: var(--ink-soft); }
.feature-card:nth-child(2) { transition-delay: 0.06s; }
.feature-card:nth-child(3) { transition-delay: 0.12s; }
.feature-card:nth-child(5) { transition-delay: 0.06s; }
.feature-card:nth-child(6) { transition-delay: 0.12s; }

@media (max-width: 900px) { .feature-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 580px) { .feature-grid { grid-template-columns: 1fr; } }

/* ═══════════ Arabic-first ═══════════ */
.arabic {
    padding: 100px 0;
    background: radial-gradient(110% 120% at 80% 10%, var(--navy-800) 0%, var(--navy-950) 70%);
    color: #eef2fc;
}
.arabic-inner { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.check-list { list-style: none; margin-top: 28px; display: flex; flex-direction: column; gap: 16px; }
.check-list li { display: flex; gap: 13px; align-items: flex-start; font-size: 16px; color: #c3cfec; }
.check-list li::before {
    content: "✓"; flex-shrink: 0; width: 24px; height: 24px; border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(74, 222, 128, 0.14); color: #4ade80; font-weight: 700; font-size: 13px; margin-top: 2px;
}
.arabic-visual { display: flex; flex-direction: column; gap: 18px; }
.mini-card {
    background: rgba(132, 172, 255, 0.06); border: 1px solid var(--line-dark);
    border-radius: 16px; padding: 22px; display: flex; flex-direction: column; gap: 12px;
    box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.5);
}
.mini-card[dir="ltr"] { transform: translateX(28px); }
html[dir="rtl"] .mini-card[dir="ltr"] { transform: translateX(-28px); }
.mini-head { display: flex; align-items: center; gap: 10px; }
.mini-avatar { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(135deg, var(--blue-600), var(--blue-400)); }
.mini-avatar.alt { background: linear-gradient(135deg, #7c5cf0, #b39bff); }
.mini-name { font-weight: 600; font-size: 15px; }
.mini-card .mini-name { font-family: var(--font-ar); }
.mini-card[dir="ltr"] .mini-name { font-family: var(--font-en); }
.mini-bar { height: 9px; border-radius: 6px; background: #2a3757; }
.mini-card .pill { margin-inline-start: 0; align-self: flex-start; }

@media (max-width: 860px) {
    .arabic-inner { grid-template-columns: 1fr; gap: 40px; }
    .mini-card[dir="ltr"], html[dir="rtl"] .mini-card[dir="ltr"] { transform: none; }
}

/* ═══════════ How it works ═══════════ */
.how { padding: 100px 0; background: var(--paper); text-align: center; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 48px; }
.step {
    background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
    padding: 34px 26px;
}
.step:nth-child(2) { transition-delay: 0.08s; }
.step:nth-child(3) { transition-delay: 0.16s; }
.step-num {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px; border-radius: 50%; font-weight: 800; font-size: 18px;
    background: linear-gradient(135deg, var(--blue-700), var(--blue-600)); color: #fff;
    margin-bottom: 18px; box-shadow: 0 8px 20px -8px rgba(47, 99, 242, 0.6);
}
.step h3 { font-size: 17.5px; margin-bottom: 8px; }
.step p { font-size: 14.5px; color: var(--ink-soft); }
.roadmap-note {
    margin-top: 48px; display: inline-flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: center;
    font-size: 14.5px; color: var(--ink-soft);
    background: #fff; border: 1px dashed rgba(124, 92, 240, 0.4); border-radius: 999px; padding: 10px 20px;
}
@media (max-width: 780px) { .steps { grid-template-columns: 1fr; } }

/* ═══════════ Early access ═══════════ */
.access {
    position: relative; overflow: hidden; padding: 110px 0;
    background: radial-gradient(120% 100% at 50% 100%, var(--navy-800) 0%, var(--navy-950) 66%);
    color: #eef2fc; text-align: center;
}
.access-bg { position: absolute; inset: 0; pointer-events: none; }
.access-inner { position: relative; }
.access .section-sub { color: #aebadb; margin-inline: auto; }
.access-form {
    max-width: 720px; margin: 46px auto 0;
    background: rgba(11, 18, 38, 0.65); border: 1px solid var(--line-dark);
    border-radius: 22px; padding: 34px; backdrop-filter: blur(8px);
    box-shadow: var(--shadow-lg); text-align: start;
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 7px; font-size: 13.5px; font-weight: 600; color: #b8c5e6; }
.field input, .field select {
    font-family: inherit; font-size: 15px; color: #eef2fc;
    background: rgba(132, 172, 255, 0.06); border: 1px solid rgba(132, 172, 255, 0.2);
    border-radius: 11px; padding: 12px 14px; outline: none;
    transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}
.field input::placeholder { color: #5c6b92; font-weight: 400; }
.field input:focus, .field select:focus {
    border-color: var(--blue-600); box-shadow: 0 0 0 3px rgba(47, 99, 242, 0.25);
    background: rgba(132, 172, 255, 0.09);
}
.field select { appearance: none; cursor: pointer; }
.field select option { background: var(--navy-800); color: #eef2fc; }
.field input:user-invalid { border-color: #f87171; }
.access-form .btn-block { margin-top: 24px; }
.btn[disabled] { opacity: 0.6; pointer-events: none; }
.form-note { margin-top: 14px; font-size: 12.5px; color: #7385ad; text-align: center; }
.form-error { margin-top: 12px; font-size: 13.5px; color: #f87171; text-align: center; }

.form-success {
    max-width: 560px; margin: 46px auto 0;
    background: rgba(11, 18, 38, 0.65); border: 1px solid rgba(74, 222, 128, 0.3);
    border-radius: 22px; padding: 48px 34px;
    animation: popIn 0.5s cubic-bezier(0.3, 1.3, 0.5, 1);
}
@keyframes popIn { from { opacity: 0; transform: scale(0.92) } to { opacity: 1; transform: scale(1) } }
.success-icon {
    width: 62px; height: 62px; margin: 0 auto 18px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 28px; font-weight: 800; color: #4ade80;
    background: rgba(74, 222, 128, 0.12); border: 1.5px solid rgba(74, 222, 128, 0.4);
}
.form-success h3 { font-size: 22px; margin-bottom: 8px; }
.form-success p { color: #aebadb; font-size: 15px; }
.success-demo {
    margin-top: 26px; padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.09);
}
.success-demo p { margin-bottom: 16px; }

/* Honeypot — clipped rather than display:none (some bots skip hidden inputs) */
.hp-field {
    position: absolute !important;
    width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%);
    pointer-events: none; opacity: 0;
}

@media (max-width: 620px) {
    .form-grid { grid-template-columns: 1fr; }
    .access-form { padding: 26px 20px; }
}

/* ═══════════ Footer ═══════════ */
.footer { background: var(--navy-950); color: #93a2c9; padding: 54px 0 40px; border-top: 1px solid var(--line-dark); }
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.footer-brand { display: flex; align-items: center; gap: 10px; color: #eef2fc; font-weight: 700; font-size: 17px; }
.footer-brand img { border-radius: 7px; }
.footer-tag { font-size: 14px; }
.footer-links { display: flex; gap: 22px; font-size: 14px; flex-wrap: wrap; justify-content: center; }
.footer-links a { color: var(--blue-400); transition: opacity 0.15s; }
.footer-links a:hover { opacity: 0.75; }
.footer-copy { font-size: 12.5px; color: #5c6b92; margin-top: 10px; display: flex; flex-direction: column; gap: 5px; }
.footer-dev a { color: #93a2c9; font-weight: 600; transition: color 0.15s; }
.footer-dev a:hover { color: var(--blue-400); }
