 /* --- خط تجوال وإعدادات الألوان العامة --- */
@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;700;800&display=swap');

:root {
  --bg-dark: #070913;
  --card-bg: rgba(16, 20, 36, 0.92);
  --primary: #00f0ff;
  --primary-glow: rgba(0, 240, 255, 0.35);
  --whatsapp: #25d366;
  --text-main: #ffffff;
  --text-muted: #94a3b8;
  --border-card: rgba(0, 240, 255, 0.22);
  --font: 'Tajawal', sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-dark);
  font-family: var(--font);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* --- خلفية الفضاء والنجوم المتحركة --- */
#space-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
  position: relative;
  z-index: 1;
}

/* --- الهيدر والتعريف بالمعرض --- */
header {
  text-align: center;
  margin-bottom: 35px;
}

.main-title {
  font-size: 2.3rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 8px;
  letter-spacing: -0.5px;
  text-shadow: 0 0 25px rgba(0, 240, 255, 0.25);
}

.subtitle {
  color: var(--text-muted);
  font-size: 1.05rem;
}

/* --- شريط أزرار تصفية الأقسام --- */
.filter-bar {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 45px;
}

.filter-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-muted);
  padding: 10px 24px;
  border-radius: 30px;
  cursor: pointer;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  transition: all 0.3s ease;
  backdrop-filter: blur(5px);
}

.filter-btn:hover {
  border-color: var(--primary);
  color: #ffffff;
  transform: translateY(-2px);
}

.filter-btn.active {
  background: var(--primary);
  color: #080a12;
  border-color: var(--primary);
  font-weight: 700;
  box-shadow: 0 0 20px var(--primary-glow);
}

/* --- شبكة المشاريع المتناسقة (CSS Grid) --- */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 30px;
  width: 100%;
}

/* --- بطاقة المشروع --- */
.project-card {
  background: var(--card-bg);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border-card);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, opacity 0.35s ease;
  backdrop-filter: blur(8px);
}

.project-card:hover {
  transform: translateY(-8px);
  border-color: rgba(0, 240, 255, 0.65);
  box-shadow: 0 16px 36px rgba(0, 240, 255, 0.22);
}

/* --- شريط المتصفح العلوي في البطاقة --- */
.mockup-header {
  background: rgba(14, 17, 30, 0.95);
  padding: 10px 14px;
  display: none !important;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.dot-red { background: #ff5f56; }
.dot-yellow { background: #ffbd2e; }
.dot-green { background: #27c93f; }

.browser-url {
  color: #8b9bb4;
  font-size: 11.5px;
  margin-right: auto;
  direction: ltr;
}

/* --- صورة المعاينة (مقاس ثابت ومضبوط نهائياً) --- */
/* إخفاء شريط المتصفح العلوي */
.mockup-header {
  display: none !important;
}

/* جعل الصورة طولية وبأبعاد واضحة مثل النموذج */
.project-img {
  width: 100% !important;
  height: auto !important;          /* لجعل الصورة تأخذ كامل طولها الطبيعي دون ضغط */
  max-height: none !important;       /* إلغاء أي حد يقص الصورة من الأسفل */
  object-fit: contain !important;    /* إظهار محتوى الصورة كاملاً بدون أي قص للأطراف */
  object-position: center top !important;
  display: block;
  border-radius: 16px 16px 0 0;
  border-bottom: 1px solid rgba(0, 240, 255, 0.2);
  background-color: #0d101d;        /* خلفية مريحة تحافظ على تناسق البطاقة */
  transition: transform 0.4s ease;
}

/* تأثير تكبير ناعم للصورة عند التمرير */
.project-card:hover .project-img {
  transform: scale(1.03);
}

/* --- المحتوى والنصوص تحت الصورة --- */
.project-content {
  padding: 22px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  gap: 12px;
}

.project-category {
  color: var(--primary);
  font-size: 12.5px;
  font-weight: 700;
}

.project-title {
  color: #ffffff;
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
}

.project-desc {
  color: var(--text-muted);
  font-size: 13.5px;
  line-height: 1.65;
  margin: 0;
  flex-grow: 1;
}
 /* --- وسوم التقنيات --- */
.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0;
}

.tech-tags .tag {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 12px;
}

/* --- زر معاينة الموقع --- */
.preview-btn {
  display: block;
  text-align: center;
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: 11px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.3s ease;
  margin-top: auto;
}

.preview-btn:hover {
  background: var(--primary);
  color: #080a12;
  box-shadow: 0 0 18px var(--primary-glow);
}

/* --- الفوتر مع وسائل التواصل المضيئة --- */
.site-footer {
  margin-top: 75px;
  padding: 45px 20px 30px;
  background: rgba(11, 14, 25, 0.95);
  border-top: 1px solid var(--border-card);
  border-radius: 24px 24px 0 0;
  text-align: center;
  position: relative;
  z-index: 1;
}

.footer-title {
  color: #ffffff;
  font-size: 1.6rem;
  margin-bottom: 8px;
}

.footer-subtitle {
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 28px;
}

.footer-buttons {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 30px;
}

.contact-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 26px;
  border-radius: 50px;
  text-decoration: none;
  font-size: 14.5px;
  font-weight: 700;
  transition: all 0.3s ease;
  backdrop-filter: blur(6px);
}

.whatsapp-pill {
  background: rgba(37, 211, 102, 0.12);
  border: 1px solid var(--whatsapp);
  color: var(--whatsapp);
}
.whatsapp-pill:hover {
  background: var(--whatsapp);
  color: #ffffff;
  box-shadow: 0 0 22px rgba(37, 211, 102, 0.45);
  transform: translateY(-3px);
}

.email-pill {
  background: rgba(0, 240, 255, 0.12);
  border: 1px solid var(--primary);
  color: var(--primary);
}
.email-pill:hover {
  background: var(--primary);
  color: #080a12;
  box-shadow: 0 0 22px var(--primary-glow);
  transform: translateY(-3px);
}

.contact-icon {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 20px;
  color: #718096;
  font-size: 13px;
}

/* --- أزرار التواصل العائمة السريعة --- */
.floating-contact {
  position: fixed;
  bottom: 25px;
  left: 25px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 100;
}

.float-btn {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.float-btn.float-whatsapp {
  background: #25d366;
  box-shadow: 0 0 15px rgba(37, 211, 102, 0.5);
}

.float-btn.float-email {
  background: #00f0ff;
  color: #080a12;
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.5);
}

.float-btn:hover {
  transform: scale(1.15) translateY(-3px);
}

.float-btn svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

/* --- التوافق التام مع الجوال --- */
@media (max-width: 768px) {
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .project-img {
    height: auto !important;
  }
  .project-content {
    padding: 16px;
  }
  .footer-buttons {
    flex-direction: column;
  }
  .contact-pill {
    width: 100%;
    justify-content: center;
  }
  .floating-contact {
    bottom: 15px;
    left: 15px;
  }
}
/* تفعيل فلترة وإخفاء البطاقات حسب القسم */
.project-card.hidden,
.project-card.hide,
.hidden,
.hide {
  display: none !important;
}