


:root {
    --primary-color: #0bb15f;
    --hover-color: #088c4a;
    --text-color: #333;
    --container-width: 1200px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

header { padding: 20px 0; background: #fff; }
header .container { display: flex; justify-content: space-between; align-items: center; }

/* جعل الـ nav حاوية مرنة للمحاذاة */
nav { display: flex; gap: 30px; align-items: center; }

/* تنسيق الروابط لتكون في منتصف الطريق عمودياً */
nav a { 
    text-decoration: none; 
    color: var(--text-color); 
    font-weight: 500; 
    transition: 0.3s;
    display: flex; /* لضمان محاذاة النص والزر */
    align-items: center; 
}


nav a:hover:not(.download-btn) { 
    color: var(--primary-color); 
}

/* تنسيق زر التحميل ليعمل بانسجام */
.download-btn { 
    background: var(--primary-color); 
    color: white !important; 
    padding: 10px 20px; 
    border-radius: 5px;
    display: inline-block; /* لضمان التعامل معه ككتلة واحدة */
}

.download-btn:hover { background: var(--hover-color); }



.hero { padding: 80px 0; background: #ffffff; }
.hero .container { display: flex; align-items: center; justify-content: space-between; gap: 50px; }
.hero-text { flex: 1; }
.hero-text h1 { font-size: 3.5rem; margin-bottom: 20px; }

.hero-right { display: flex; align-items: center; gap: 40px; }
.hero-img { width: 320px; height: 320px; background-size: cover; background-position: center; border-radius: 20px; }

.social-icons { display: flex; flex-direction: column; gap: 20px; }
.social-icons a { transition: 0.3s; fill: var(--text-color); }
.social-icons a:hover { transform: scale(1.2); fill: var(--primary-color); }

.menu-toggle { display: none; cursor: pointer; }


.hero-img-element {
    width: 100%;        /* ستأخذ عرض الحاوية الأب */
    height: auto;       /* للحفاظ على تناسق الأبعاد */
    max-width: 600px;   /* تحكم بالحجم الأقصى حسب حاجتك */
    display: block;     /* منع أي مسافات إضافية تحت الصورة */
    border-radius: 20px; /* إذا أردت حواف دائرية */
    object-fit: cover;
}



@media (max-width: 768px) {
    .menu-toggle { display: block; }
    nav { 
        display: none; position: absolute; top: 80px; left: 0; width: 100%; 
        background: #fff; flex-direction: column; padding: 20px; text-align: center;
    }
    nav.active { display: flex; }
    
    .hero .container { flex-direction: column; text-align: center; }
    
    .hero-right { 
        display: flex !important;
        flex-direction: row !important; 
        justify-content: center;
        align-items: center;
        gap: 15px !important;
        flex-wrap: nowrap; 
    }
    
    .hero-img { width: 200px !important; height: 200px !important; }
    .social-icons { flex-direction: column !important; }
}



/* Stats Section */
.stats { padding: 50px 0; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; text-align: center; }
.stats-grid h2 { font-size: 40px; color: var(--primary-color); }

/* Skills Section */
.skills { padding: 80px 0; }
.skills-wrapper { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-start; }
.skills-text { flex: 1; min-width: 300px; }

.badge { 
    color: var(--primary-color); font-weight: bold; 
    border: 1px solid var(--primary-color); padding: 5px 15px; border-radius: 20px;
}
.skills-text h2 { font-size: 40px; margin: 20px 0; }
.skills-text p { color: #666; margin-bottom: 30px; }
.hire-btn { 
    background: var(--primary-color); color: white; padding: 12px 30px; 
    text-decoration: none; border-radius: 5px; display: inline-block; 
}

/* Skills Grid */
.skills-grid { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.skill-card { padding: 20px; border: 1px solid #eee; border-radius: 15px; }
.skill-card .icon { font-size: 30px; color: var(--primary-color); margin-bottom: 10px; }
.skill-card p { font-size: 14px; color: #666; }

/* Responsive */
@media (max-width: 768px) {
    .stats-grid { grid-template-columns: 1fr; }
    .skills-grid { grid-template-columns: 1fr; }
}



/* تنسيق قسم المعرض */
.proGallery-wrapper { padding: 80px 0; }

.portfolio-badge {
    color: var(--primary-color);
    font-weight: bold;
    border: 1px solid var(--primary-color);
    padding: 5px 15px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 20px;
}

.portfolio-filter { display: flex; justify-content: center; gap: 10px; margin-bottom: 40px; }

.f-btn {
    padding: 8px 20px; border: none; cursor: pointer;
    background: #f0f0f0; border-radius: 5px; transition: 0.3s;
}
.f-btn.active { background: var(--primary-color); color: white; }

.proGallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

.pg-box { position: relative; border-radius: 15px; overflow: hidden; }
.pg-box img { width: 100%; height: 250px; object-fit: cover; transition: 0.5s; }

.pg-overlay {
    position: absolute; inset: 0; background: rgba(0,0,0,0.6);
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    opacity: 0; transition: 0.3s;
}
.pg-box:hover .pg-overlay { opacity: 1; }
.pg-box:hover img { transform: scale(1.1); }

.pg-overlay-title { color: white; font-size: 1.2rem; margin-bottom: 10px; }
.pg-btn { background: white; border: none; padding: 10px; cursor: pointer; border-radius: 5px; margin: 0 5px; }




/* --- Professional Dark Lightbox --- */
#pg-lightbox {
  border: none;
  padding: 0;
  background: transparent;
  max-width: 900px; /* Slightly larger for impact */
  width: 90%;
  border-radius: 20px;
  /* Key for centering vertically and horizontally */
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
}

/* Dimming background overlay */
#pg-lightbox::backdrop {
  background: rgba(0, 0, 0, 0.9); /* Darker dimming for focus */
}

.lb-outer {
  background: #111; /* Dark outer container for focus */
  padding: 30px;
  border-radius: 20px;
  position: relative;
  box-shadow: 0 30px 60px rgba(0,0,0,0.5); /* Deep shadow for depth */
}

.lb-main-area {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lb-img-container img {
  width: 100%;
  height: auto;
  max-height: 75vh; /* Optimal height for viewing */
  object-fit: contain;
  border-radius: 12px;
}

/* --- Specific Request: Black Circle Close Button (Top Right) --- */
.lb-close {
  position: absolute;
  top: -45px; /* Offset to float slightly above outer area */
  right: 0;
  background: #000; /* Solid Black Background */
  color: #fff;      /* White Text */
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%; /* Circle shape */
  cursor: pointer;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: background 0.3s ease;
}

.lb-close:hover {
  background: #333; /* Slightly lighter on hover */
}

/* --- Specific Request: Floating Nav Arrows (Mid-Left & Mid-Right) --- */
.lb-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%); /* Vertical centering */
  background: rgba(255, 255, 255, 0.1); /* Subtle white base */
  border: none;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 22px;
  color: #fff;
  transition: all 0.3s ease;
}

.lb-nav-btn:hover {
  background: var(--primary-color); /* Your green primary color on hover */
  color: #fff;
}

.prev {
  left: 20px; /* Floating on left side */
}

.next {
  right: 20px; /* Floating on right side */
}

/* --- Dark Modal Info Styling --- */
.lb-footer-info {
  text-align: center;
  padding: 20px 0 10px 0;
}

.lb-footer-info h4 {
  color: #fff; /* White title for dark theme */
  margin: 0;
}

/* --- تعديل زر الإغلاق لضمان ظهوره في أقصى اليمين من الأعلى --- */
.lb-close {
  position: absolute;
  top: 15px;      /* داخل الحاوية من الأعلى */
  right: 15px;    /* داخل الحاوية من اليمين */
  background: #000; 
  color: #fff;      
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%; 
  cursor: pointer;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20;    /* لضمان أن يكون فوق أي عنصر آخر */
  transition: background 0.3s ease;
}

.lb-close:hover {
  background: #333;
}

/* قسم التقييمات */
.testimonials { padding: 80px 0; background: #fff; }
.testi-header { margin-bottom: 50px; }
.testi-header h2 { font-size: 2.5rem; margin-top: 10px; }

.testi-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 30px; 
}

.testi-card { 
    padding: 30px; 
    border: 1px solid #f0f0f0; 
    border-radius: 20px; 
    transition: 0.3s;
}
.testi-card:hover { box-shadow: 0 10px 30px rgba(0,0,0,0.05); }

.stars { color: #ffb400; margin-bottom: 15px; font-size: 1.2rem; }
.testi-card p { color: #666; margin-bottom: 20px; line-height: 1.6; }

.client-info { display: flex; align-items: center; gap: 15px; }
.client-info img { width: 50px; height: 50px; border-radius: 50%; object-fit: cover; }
.client-info h4 { margin: 0; }
.client-info small { color: #999; }

.section-badge {
    display: inline-block;
    color: var(--primary-color); /* اللون الأخضر المعتمد */
    font-weight: bold;
    border: 1px solid var(--primary-color);
    padding: 5px 20px; /* زيادة بسيطة لراحة الكلمة */
    border-radius: 20px;
    font-size: 14px;
    margin-bottom: 15px;
    text-transform: capitalize;
}


/* --- تنسيق قسم الاتصال --- */
.contact-section { padding: 80px 0; background: #fff; }

.contact-wrapper { 
    display: grid; 
    grid-template-columns: 1fr 1.5fr; 
    gap: 60px; 
    margin-top: 50px; 
}

.info-item { display: flex; align-items: flex-start; gap: 20px; margin-bottom: 30px; }

.icon-box {
    background: var(--primary-color);
    color: white;
    padding: 12px;
    border-radius: 12px;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-box svg { width: 24px; height: 24px; stroke: white; }

.info-item small { color: #888; font-size: 0.85rem; display: block; }
.info-item h4 { margin: 5px 0 0 0; font-size: 1.1rem; color: #333; }

/* تنسيق النموذج */
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
.contact-form input, .contact-form textarea { 
    padding: 15px; border: 1px solid #eee; border-radius: 10px; width: 100%; 
}
.contact-form textarea { height: 140px; margin-bottom: 20px; }
.submit-btn { 
    background: var(--primary-color); color: white; border: none; 
    padding: 15px 30px; border-radius: 10px; cursor: pointer; width: 100%; font-weight: bold;
}

/* --- تنسيق الفوتر --- */
.main-footer { padding: 40px 0; border-top: 1px solid #eee; margin-top: 50px; }
.footer-content { display: flex; justify-content: space-between; align-items: center; }

.footer-icons { display: flex; gap: 20px; }
.footer-icons a { 
    display: flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; background: #f4f4f4; border-radius: 50%;
    transition: 0.3s;
}
.footer-icons a:hover { background: var(--primary-color); }
.footer-icons a svg { fill: #333; transition: 0.3s; width: 20px; }
.footer-icons a:hover svg { fill: white; }

/* تحسين للجوال */
@media (max-width: 768px) {
    .contact-wrapper { grid-template-columns: 1fr; }
    .form-row { grid-template-columns: 1fr; }
}