* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Cairo', sans-serif;
    background: linear-gradient(135deg, #0a0f1a 0%, #0f1a2e 100%);
    color: #fff;
    min-height: 100vh;
    direction: rtl;
}

.container {
    max-width: 550px;
    margin: 0 auto;
    padding: 20px 16px 40px;
    position: relative;
    z-index: 1;
}

/* ========== شريط اللغة ========== */
.lang-bar {
    background: rgba(10, 15, 26, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 215, 0, 0.2);
    padding: 6px 16px;
    text-align: left;
}
html[dir="rtl"] .lang-bar { text-align: right; }

.lang-bar-inner {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 30px;
    padding: 3px;
    border: 1px solid rgba(255, 215, 0, 0.15);
}

.lang-btn-2 {
    padding: 5px 12px;
    border-radius: 30px;
    border: 1.5px solid transparent;
    background: transparent;
    color: #aaa;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Cairo', sans-serif;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-width: 80px;
    justify-content: center;
}

.lang-btn-2:hover {
    background: rgba(255, 215, 0, 0.08);
    color: #FFD700;
    border-color: rgba(255, 215, 0, 0.3);
}

.lang-btn-2.active {
    background: rgba(255, 215, 0, 0.18);
    color: #FFD700;
    border-color: #FFD700;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.15);
}

/* ========== جزيئات الخلفية ========== */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.particle {
    position: absolute;
    border-radius: 50%;
    animation: floatUpParticle linear infinite;
    opacity: 0;
    box-shadow: 0 0 8px 2px rgba(255,215,0,0.5);
}

.particle.gold {
    background: radial-gradient(circle, rgba(255,215,0,0.9) 0%, rgba(255,180,0,0.4) 50%, transparent 70%);
}

.particle.light {
    background: radial-gradient(circle, rgba(255,255,255,0.6) 0%, rgba(255,215,0,0.3) 50%, transparent 70%);
}

@keyframes floatUpParticle {
    0% {
        transform: translateY(105vh) scale(0);
        opacity: 0;
    }
    5% {
        opacity: 0.9;
    }
    70% {
        opacity: 0.3;
    }
    100% {
        transform: translateY(-5vh) scale(1.5);
        opacity: 0;
    }
}

/* ========== هيدر ========== */
.app-header { text-align: center; margin-bottom: 20px; }

.app-icon-img {
    width: 90px; height: 90px; border-radius: 25px; margin: 0 auto 12px;
    display: block; cursor: pointer; transition: transform 0.3s; object-fit: cover;
    box-shadow: 0 15px 30px -8px rgba(0,0,0,0.5), 0 0 0 2px rgba(255,215,0,0.2);
}
.app-icon-img:hover { transform: scale(1.05); }

h1 {
    font-size: 26px; font-weight: 800;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text; margin-bottom: 5px;
}
.subtitle { color: #8cb3d9; font-size: 13px; margin-bottom: 15px; }

/* ========== صندوق التحميل ========== */
.main-download-box {
    background: linear-gradient(145deg, #0f172a, #0a0f1a);
    border: 1px solid rgba(255,215,0,0.3); border-radius: 24px;
    padding: 22px 18px; margin-bottom: 20px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.3); text-align: center;
}

.shake-vertical {
    animation: shakeVertical 2.5s ease-in-out infinite;
}

@keyframes shakeVertical {
    0%, 100% { transform: translateY(0); }
    5% { transform: translateY(-4px); }
    10% { transform: translateY(0); }
    15% { transform: translateY(-3px); }
    20% { transform: translateY(0); }
    25%, 100% { transform: translateY(0); }
}

.main-download-btn {
    display: inline-flex; align-items: center; justify-content: center;
    gap: 12px; background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #0a0f1a; padding: 16px 40px; border-radius: 50px;
    font-size: 18px; font-weight: 800; cursor: pointer; border: none;
    font-family: 'Cairo', sans-serif;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 8px 25px rgba(255,215,0,0.3);
    position: relative; overflow: hidden;
}

.main-download-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(255,215,0,0.5), 0 0 40px rgba(255,215,0,0.2);
    animation: none;
}
.main-download-btn:active { transform: scale(0.96); }

.main-download-btn.counting {
    animation: pulseCountdown 1s ease-in-out infinite !important;
}

.main-download-btn .ripple {
    position: absolute; border-radius: 50%;
    background: rgba(255,255,255,0.5);
    transform: scale(0); animation: rippleEffect 0.6s linear; pointer-events: none;
}
@keyframes rippleEffect { to { transform: scale(4); opacity: 0; } }

.main-download-btn.counting {
    background: linear-gradient(135deg, #555, #333); color: #ccc;
    cursor: not-allowed; pointer-events: none;
}
@keyframes pulseCountdown {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

.countdown-number {
    display: inline-block; background: rgba(0,0,0,0.3); color: #FFD700;
    width: 32px; height: 32px; line-height: 32px; border-radius: 50%;
    font-weight: 800; font-size: 18px; margin: 0 4px;
}

.download-choice-text {
    text-align: center; color: #FFD700; font-size: 15px; font-weight: 700;
    margin-top: 18px; display: flex; align-items: center; justify-content: center;
    gap: 10px; animation: fadeInUp 0.5s ease;
}
.download-choice-text .arrow-down {
    display: inline-block; animation: bounceDown 1s infinite;
    font-size: 18px; color: #FFA500;
}
.download-choice-text .arrow-down:nth-child(1) { animation-delay: 0s; }
.download-choice-text .arrow-down:nth-child(3) { animation-delay: 0.2s; }

@keyframes bounceDown {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(8px); }
}
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

.download-options {
    max-height: 0; overflow: hidden;
    transition: max-height 0.5s ease, opacity 0.4s ease, margin 0.4s ease;
    opacity: 0; margin-top: 0;
}
.download-options.show { max-height: 350px; opacity: 1; margin-top: 18px; }

.download-row { display: flex; gap: 12px; margin-bottom: 12px; }

.download-btn {
    flex: 1; display: inline-flex; align-items: center; justify-content: center;
    gap: 8px; padding: 12px 12px; border-radius: 50px; font-size: 14px;
    font-weight: 700; cursor: pointer; text-decoration: none; text-align: center;
    font-family: 'Cairo', sans-serif; position: relative; overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.3s ease, background 0.3s ease;
}
.download-btn:hover { transform: translateY(-2px); }
.download-btn:active { transform: scale(0.97); }

.download-btn .ripple {
    position: absolute; border-radius: 50%; background: rgba(255,255,255,0.4);
    transform: scale(0); animation: rippleEffect 0.6s linear; pointer-events: none;
}

.download-btn.primary {
    background: linear-gradient(95deg, #004d00, #007700); color: white;
    border: 1.5px solid #00ff00;
}
.download-btn.primary:hover {
    box-shadow: 0 5px 20px rgba(0,255,0,0.4), 0 0 30px rgba(0,255,0,0.15);
}

.download-btn.mediafire {
    border: 1.5px solid #FF6B35; color: #FF6B35;
    background: linear-gradient(95deg, #1a1510, #2a1a10);
}
.download-btn.mediafire:hover {
    background: rgba(255,107,53,0.15);
    box-shadow: 0 5px 20px rgba(255,107,53,0.4), 0 0 30px rgba(255,107,53,0.15);
}
.download-icon { font-size: 16px; }

.qr-inline {
    display: flex; align-items: center; justify-content: space-between;
    background: rgba(0,0,0,0.3); border-radius: 16px; padding: 10px 15px; margin-top: 5px;
}
.qr-text { display: flex; flex-direction: column; gap: 5px; }
.qr-text span:first-child { color: #FFD700; font-size: 13px; font-weight: 700; }
.qr-text span:last-child { color: #8cb3d9; font-size: 10px; }

.qr-code-box {
    width: 130px; height: 130px; background: white; border-radius: 14px;
    padding: 8px; display: flex; align-items: center; justify-content: center;
    cursor: pointer; transition: transform 0.2s;
}
.qr-code-box:hover { transform: scale(1.02); }
.qr-code-box img { width: 100%; height: 100%; object-fit: contain; border-radius: 8px; }

/* ========== إحصائيات ========== */
.stats-cards {
    display: flex; justify-content: center; gap: 10px;
    margin-bottom: 20px; flex-wrap: nowrap;
}
.stat-card {
    background: linear-gradient(145deg, #1a2535, #0f172a); border-radius: 16px;
    padding: 8px 10px; text-align: center; flex: 1; min-width: 0;
    border: 1px solid rgba(255,215,0,0.2);
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}
.stat-card:hover {
    border-color: #FFD700; transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(255,215,0,0.15);
}
.stat-icon { font-size: 16px; margin-bottom: 2px; }
.stat-number { font-size: 18px; font-weight: 800; color: #FFD700; line-height: 1.3; }
.stat-label { font-size: 10px; color: #8cb3d9; letter-spacing: 0.5px; }

/* ========== تواصل اجتماعي ========== */
.social-grid { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

.social-btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 18px; border-radius: 50px; text-decoration: none;
    font-weight: 700; font-size: 13px; font-family: 'Cairo', sans-serif;
    border: 1.5px solid transparent; color: #fff;
    flex-shrink: 0; white-space: nowrap; position: relative; overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.3s ease, background 0.3s ease;
}
.social-btn .ripple {
    position: absolute; border-radius: 50%; background: rgba(255,255,255,0.4);
    transform: scale(0); animation: rippleEffect 0.6s linear; pointer-events: none;
}
.social-btn:hover { transform: translateY(-3px); }
.social-btn:active { transform: scale(0.95); }

.social-btn.whatsapp { background: #075e54; border-color: #25D366; }
.social-btn.whatsapp:hover { box-shadow: 0 6px 25px rgba(37,211,102,0.5), 0 0 40px rgba(37,211,102,0.2); background: #0a7a6d; }

.social-btn.telegram { background: #0088cc; border-color: #00aaff; }
.social-btn.telegram:hover { box-shadow: 0 6px 25px rgba(0,168,255,0.5), 0 0 40px rgba(0,168,255,0.2); background: #0099dd; }

.social-btn.facebook { background: #1877f2; border-color: #4292f5; }
.social-btn.facebook:hover { box-shadow: 0 6px 25px rgba(24,119,242,0.5), 0 0 40px rgba(24,119,242,0.2); background: #1a80ff; }

.social-icon { font-size: 18px; flex-shrink: 0; }

/* ========== شارة الأمان ========== */
.security-badge {
    text-align: center;
    background: linear-gradient(145deg, rgba(0,100,0,0.2), rgba(0,50,0,0.1));
    border: 1px solid rgba(0,255,0,0.3);
    border-radius: 50px;
    padding: 12px 20px;
    margin-bottom: 25px;
    font-size: 12px;
    color: #00ff88;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.security-badge i { color: #00ff88; font-size: 16px; }

/* ========== ما الجديد - Accordion ========== */
.changelog-toggle {
    width: 100%;
    background: linear-gradient(145deg, #1a2535, #0f172a);
    border: 1px solid rgba(255,215,0,0.3);
    border-radius: 16px;
    padding: 14px 18px;
    color: #FFD700;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Cairo', sans-serif;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.3s;
}
.changelog-toggle:hover {
    border-color: #FFD700;
    box-shadow: 0 5px 20px rgba(255,215,0,0.2);
}
.changelog-arrow {
    transition: transform 0.3s ease;
    font-size: 14px;
}
.changelog-arrow.open {
    transform: rotate(180deg);
}

.changelog-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, margin 0.3s ease;
    margin-top: 0;
}
.changelog-body.show {
    max-height: 400px;
    margin-top: 12px;
}

.changelog-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.changelog-item {
    background: rgba(30, 41, 59, 0.5);
    border-radius: 12px;
    padding: 10px 14px;
    font-size: 13px;
    color: #cbd5f0;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(255,215,0,0.1);
    transition: all 0.3s;
}
.changelog-item:hover {
    border-color: #FFD700;
    background: rgba(30, 41, 59, 0.8);
}
.changelog-item i { color: #00ff88; font-size: 14px; flex-shrink: 0; }

/* ========== أقسام ========== */
.section { margin-bottom: 30px; }
.section-title {
    font-size: 20px; font-weight: 700; color: #FFD700;
    text-align: center; margin-bottom: 18px; position: relative;
}
.section-title:after {
    content: ''; position: absolute; bottom: -6px; left: 50%;
    transform: translateX(-50%); width: 50px; height: 2px;
    background: linear-gradient(90deg, #FFD700, #FFA500); border-radius: 2px;
}

/* ========== مميزات ========== */
.features-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.feature-card {
    background: rgba(30, 41, 59, 0.7); backdrop-filter: blur(5px);
    border: 1px solid rgba(30,144,255,0.25); border-radius: 14px;
    padding: 10px 8px; text-align: center;
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}
.feature-card:hover {
    border-color: #FFD700; transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(255,215,0,0.2);
}
.feature-icon { font-size: 24px; margin-bottom: 5px; }
.feature-title { font-weight: 700; font-size: 12px; color: #fff; }

/* ========== سلايدر ========== */
.slider-container {
    position: relative; overflow-x: auto; overflow-y: hidden;
    white-space: nowrap; scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch; scrollbar-width: thin;
    scrollbar-color: #FFD700 #1e293b; border-radius: 20px; padding: 5px 0;
}
.slider-container::-webkit-scrollbar { height: 4px; }
.slider-container::-webkit-scrollbar-track { background: #1e293b; border-radius: 10px; }
.slider-container::-webkit-scrollbar-thumb { background: #FFD700; border-radius: 10px; }

.screenshots-slider { display: inline-flex; gap: 15px; padding: 5px 10px; }
.screenshot-card {
    scroll-snap-align: start; width: 240px; flex-shrink: 0;
    background: #1e293b; border-radius: 20px; padding: 10px;
    border: 1px solid rgba(30,144,255,0.3); white-space: normal;
    cursor: pointer; transition: transform 0.3s, box-shadow 0.3s;
}
.screenshot-card:hover { transform: scale(1.03); box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.screenshot-img {
    width: 100%; background: #0f172a; border-radius: 14px; overflow: hidden;
    min-height: 280px; display: flex; align-items: center; justify-content: center;
}
.screenshot-img img { width: 100%; height: auto; display: block; cursor: pointer; }
.screenshot-label { text-align: center; margin-top: 8px; font-size: 11px; color: #94a3b8; }
.slider-hint {
    text-align: center; color: #6c86a3; font-size: 11px; margin-top: 8px;
    display: flex; align-items: center; justify-content: center; gap: 8px;
}

/* ========== آراء ========== */
.testimonials-grid {
    display: flex; flex-direction: column; gap: 12px;
    margin-top: 15px; max-height: 450px; overflow-y: auto; padding: 5px;
}
.testimonials-grid::-webkit-scrollbar { width: 3px; }
.testimonials-grid::-webkit-scrollbar-track { background: #1e293b; border-radius: 10px; }
.testimonials-grid::-webkit-scrollbar-thumb { background: #FFD700; border-radius: 10px; }

.testimonial-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(20, 30, 45, 0.6));
    border: 1px solid rgba(255,215,0,0.2); border-radius: 16px; padding: 14px;
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}
.testimonial-card:hover {
    border-color: #FFD700; transform: translateX(-4px);
    box-shadow: 0 8px 20px rgba(255,215,0,0.15);
}
.testimonial-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.testimonial-avatar {
    width: 42px; height: 42px; background: linear-gradient(145deg, #1a3a2a, #0d2a1a);
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 20px; border: 1px solid #FFD700; flex-shrink: 0;
}
.testimonial-info { flex: 1; }
.testimonial-name { font-weight: 700; color: #FFD700; font-size: 14px; }
.testimonial-rating { color: #FFD700; font-size: 11px; letter-spacing: 2px; }
.testimonial-text { color: #cbd5f0; font-size: 12px; line-height: 1.5; margin-bottom: 6px; }
.testimonial-date { color: #6c86a3; font-size: 10px; }

/* ========== فوتر ========== */
.footer {
    margin-top: 30px; padding-top: 15px; border-top: 1px solid #334155;
    text-align: center; color: #64748b; font-size: 11px;
}
.footer a { color: #FFD700; text-decoration: none; }
.footer a:hover { color: #FFA500; text-decoration: underline; }

/* ========== زر الرجوع للأعلى ========== */
#backToTop {
    position: fixed; bottom: 25px; right: 20px;
    background: #FFD700; color: #0a0f1a;
    border: none; width: 45px; height: 45px; border-radius: 50%;
    font-size: 18px; cursor: pointer; z-index: 999;
    box-shadow: 0 4px 15px rgba(255,215,0,0.4);
    transition: all 0.3s; display: none;
    justify-content: center; align-items: center;
}
#backToTop.show { display: flex; }
#backToTop:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255,215,0,0.6);
}

/* ========== Drag hint ========== */
.drag-hint {
    position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%);
    background: rgba(0,0,0,0.85); color: #FFD700; padding: 8px 16px;
    border-radius: 30px; font-size: 12px; z-index: 1000; pointer-events: none;
    opacity: 0; transition: opacity 0.4s; white-space: nowrap;
    border: 1px solid rgba(255,215,0,0.4);
}

/* ========== جوال ========== */
@media (max-width: 480px) {
    .lang-bar { padding: 5px 12px; }
    .lang-btn-2 { padding: 4px 10px; font-size: 10px; min-width: 70px; }
    .container { padding: 12px 12px 30px; }
    .stat-card { padding: 6px 8px; }
    .stat-number { font-size: 16px; }
    .stat-icon { font-size: 14px; }
    .stat-label { font-size: 9px; }
    .download-btn { font-size: 12px; padding: 10px 8px; }
    .screenshot-card { width: 200px; }
    .screenshot-img { min-height: 240px; }
    .qr-code-box { width: 110px; height: 110px; }
    .main-download-btn { font-size: 16px; padding: 14px 30px; }
    .social-btn { padding: 8px 14px; font-size: 12px; gap: 6px; }
    .social-icon { font-size: 16px; }
    .download-choice-text { font-size: 13px; gap: 6px; }
    .download-choice-text .arrow-down { font-size: 15px; }
    .security-badge { font-size: 11px; padding: 10px 14px; }
    .changelog-toggle { font-size: 14px; padding: 12px 14px; }
    .changelog-item { font-size: 12px; padding: 8px 10px; }
    #backToTop { width: 40px; height: 40px; font-size: 16px; bottom: 15px; right: 12px; }
}