/* ================= المتغيرات الأساسية ================= */
:root {
    --primary: #00796b;
    --primary-hover: #004d40;
    --secondary: #0a192f;
    --light-bg: #f4f8f9;
    --white: #ffffff;
    --text-main: #334155;
    --text-muted: #64748b;
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 20px -5px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease-in-out;
}

/* ================= الإعدادات العامة ومنع التمرير الجانبي ================= */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

html, body { 
    scroll-behavior: smooth; 
    overflow-x: hidden; /* يمنع تحرك الشاشة يميناً ويساراً في الجوال */
    width: 100%;
}

body {
    font-family: 'Tajawal', sans-serif;
    color: var(--text-main);
    line-height: 1.6;
    background-color: var(--white);
}

body.en-font { font-family: 'Poppins', sans-serif; }

.container { 
    width: 100%;
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 0 15px; /* تصغير الحواف الجانبية للموبايل */
}

.section-padding { padding: 60px 0; } /* تصغير المسافات بين الأقسام */
.bg-light { background: var(--light-bg); }
.text-center { text-align: center; }
a { text-decoration: none; color: inherit; }

/* ================= الهيدر ================= */
header {
    position: fixed; 
    width: 100%; 
    top: 0; 
    z-index: 1000;
    transition: var(--transition); 
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow-sm);
    padding: 10px 0;
}

.header-container { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
}

.logo span { display: block; font-size: 1.2rem; font-weight: 800; color: var(--primary); }
.logo small { font-size: 0.75rem; color: var(--secondary); font-weight: 600; }

.nav-links { display: flex; list-style: none; gap: 20px; }
.nav-links a { color: var(--secondary); font-weight: 700; font-size: 0.95rem; }
.nav-footer-mobile { display: none; }

.header-actions { display: flex; align-items: center; gap: 10px; }

.lang-btn {
    background: var(--light-bg); 
    border: 1px solid #e2e8f0; 
    padding: 6px 12px;
    border-radius: 50px; 
    font-size: 0.85rem;
    font-weight: 700; 
    color: var(--primary); 
    cursor: pointer;
}

.menu-btn { 
    display: none; 
    font-size: 1.5rem; 
    background: none; 
    border: none; 
    color: var(--secondary); 
    cursor: pointer; 
}

/* ================= الهيرو (الواجهة) ================= */
.hero {
    position: relative; 
    padding: 130px 0 60px; /* مسافة أمنة للموبايل */
    background: url('https://images.unsplash.com/photo-1512678080530-7760d81faba6?auto=format&fit=crop&w=1920&q=80') center/cover;
    color: var(--white);
    min-height: auto;
}

.hero-overlay { 
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; 
    background: linear-gradient(rgba(10, 25, 47, 0.85), rgba(0, 121, 107, 0.75)); 
}

.hero-wrapper { position: relative; z-index: 2; }
.hero-content { max-width: 100%; }

.badge { 
    background: var(--primary); 
    padding: 5px 12px; 
    border-radius: 50px; 
    font-size: 0.8rem; 
    font-weight: 700; 
    display: inline-block; 
    margin-bottom: 15px; 
}

.hero h1 { font-size: 2rem; font-weight: 800; margin-bottom: 15px; line-height: 1.4; }
.hero p { font-size: 1rem; opacity: 0.9; margin-bottom: 25px; }

.hero-btns { display: flex; flex-direction: column; gap: 10px; width: 100%; } /* الأزرار تحت بعض في الجوال */
.btn { 
    padding: 12px 20px; 
    border-radius: 50px; 
    font-weight: 700; 
    display: inline-flex; 
    align-items: center; 
    justify-content: center; 
    font-size: 1rem;
    width: 100%; /* أزرار بعرض الشاشة في الهاتف */
    text-align: center;
}
.btn-primary { background: var(--primary); color: var(--white); border: 2px solid var(--primary); }
.btn-white-outline { border: 2px solid var(--white); color: var(--white); }

/* ================= شريط الثقة ================= */
.trust-bar { background: var(--light-bg); padding: 30px 0; }
.trust-container { 
    display: flex; 
    flex-direction: column; /* عمودي في الموبايل */
    gap: 15px; 
}
.trust-item { 
    display: flex; 
    align-items: center; 
    gap: 15px; 
    background: var(--white); 
    padding: 15px; 
    border-radius: 12px; 
    box-shadow: var(--shadow-sm); 
}
.trust-item i { font-size: 2rem; color: var(--primary); }
.trust-item strong { display: block; font-size: 1rem; color: var(--secondary); }
.trust-item span { font-size: 0.85rem; color: var(--text-muted); }

/* ================= عن أحمد ================= */
.about-wrapper { display: flex; flex-direction: column; gap: 30px; }
.about-image { position: relative; width: 100%; }
.about-image img { width: 100%; border-radius: 15px; }
.exp-card { 
    position: absolute; bottom: 10px; left: 10px; 
    background: var(--primary); color: var(--white); 
    padding: 15px; border-radius: 12px; text-align: center; 
}
.exp-card span { font-size: 1.5rem; font-weight: 800; display: block; }
.exp-card p { font-size: 0.8rem; }

.about-text h2 { font-size: 1.8rem; margin-bottom: 15px; color: var(--secondary); }
.about-p1 { font-size: 0.95rem; }
.about-list { list-style: none; margin-top: 15px; }
.about-list li { margin-bottom: 12px; font-weight: 700; display: flex; align-items: flex-start; gap: 10px; font-size: 0.9rem;}
.about-list i { color: var(--primary); font-size: 1.1rem; margin-top: 4px;}

/* ================= الخطوات والخدمات ================= */
.section-title { margin-bottom: 30px; text-align: center; }
.section-title h2 { font-size: 1.8rem; color: var(--secondary); margin-bottom: 5px; }
.section-title p { color: var(--primary); font-weight: 700; font-size: 0.9rem; }

.process-grid, .services-grid, .gallery-grid { 
    display: flex; 
    flex-direction: column; /* كل البطاقات تحت بعض في الهاتف */
    gap: 15px; 
}
.process-step, .service-card { 
    background: var(--white); padding: 25px 20px; border-radius: 15px; 
    text-align: center; box-shadow: var(--shadow-sm); 
}
.step-num { 
    width: 40px; height: 40px; background: var(--primary); color: var(--white); 
    border-radius: 50%; display: flex; align-items: center; justify-content: center; 
    font-weight: 800; font-size: 1rem; margin: 0 auto 15px; 
}
.service-card i { font-size: 2.5rem; color: var(--primary); margin-bottom: 15px; }

/* ================= الصور ================= */
.gallery-item { border-radius: 15px; overflow: hidden; height: 250px; position: relative; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; }
.overlay { 
    position: absolute; bottom: 0; width: 100%; 
    background: linear-gradient(transparent, rgba(0,0,0,0.9)); 
    color: var(--white); padding: 15px; text-align: center; font-size: 1rem; font-weight: 700;
}

/* ================= التواصل ================= */
.contact-box { 
    background: var(--secondary); color: var(--white); padding: 30px 20px; 
    border-radius: 20px; text-align: center; 
}
.contact-info h2 { font-size: 1.6rem; margin-bottom: 10px; }
.contact-info p { font-size: 0.9rem; margin-bottom: 20px; }
.info-item-contact { display: flex; justify-content: center; align-items: center; gap: 10px; font-size: 1rem; margin-bottom: 15px; }
.info-item-contact i { color: var(--primary); font-size: 1.2rem; }

/* ================= الأزرار العائمة للموبايل ================= */
.floating-socials { 
    position: fixed; bottom: 15px; left: 15px; z-index: 1000; 
    display: flex; flex-direction: column; gap: 10px; 
}
.floating-socials a { 
    width: 50px; height: 50px; border-radius: 50%; 
    display: flex; align-items: center; justify-content: center; 
    font-size: 1.6rem; color: var(--white); box-shadow: 0 5px 15px rgba(0,0,0,0.3); 
}
.float-wa { background: #25d366; }
.float-fb { background: #1877f2; }

footer { background: #050c16; color: #94a3b8; padding: 20px 0; font-size: 0.85rem; text-align: center; }

/* ================= التجاوب مع شاشات الكمبيوتر والتابلت ================= */
@media (min-width: 768px) {
    .container { padding: 0 24px; }
    .section-padding { padding: 90px 0; }
    .hero { padding: 180px 0 100px; text-align: right; }
    .hero h1 { font-size: 3.2rem; }
    .hero-btns { flex-direction: row; width: auto; }
    .btn { width: auto; }
    
    .trust-bar { margin-top: -50px; background: transparent; padding: 0; }
    .trust-container { flex-direction: row; grid-template-columns: repeat(3, 1fr); padding: 30px; border-radius: 20px; }
    
    .about-wrapper { flex-direction: row; }
    .process-grid { display: grid; grid-template-columns: repeat(2, 1fr); }
    .services-grid { display: grid; grid-template-columns: repeat(2, 1fr); }
    .gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); }
    
    .contact-box { display: grid; grid-template-columns: 1fr 1fr; text-align: right; padding: 50px; }
    .info-item-contact { justify-content: flex-start; }
    .floating-socials { bottom: 30px; left: 30px; }
    .floating-socials a { width: 60px; height: 60px; font-size: 2rem; border-radius: 20px; }
}

@media (min-width: 1024px) {
    .process-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ================= القائمة الجانبية للموبايل ================= */
@media (max-width: 767px) {
    .menu-btn { display: block; }
    nav { 
        position: fixed; top: 0; right: -100%; width: 260px; height: 100vh; 
        background: var(--white); flex-direction: column; padding: 80px 20px; 
        transition: 0.3s ease-in-out; box-shadow: -5px 0 15px rgba(0,0,0,0.1); 
        z-index: 999;
    }
    nav.active { right: 0; }
    .nav-links { flex-direction: column; gap: 25px; width: 100%; }
    .nav-links a { font-size: 1.1rem; }
    .nav-footer-mobile { display: block; margin-top: 40px; text-align: center; }
}

/* تأثير الظهور */
.fade-in { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease-out, transform 0.6s ease-out; }
.fade-in.visible { opacity: 1; transform: translateY(0); }