@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;600;700;800&display=swap');

:root {
  --bg-primary: #020A24;
  --bg-secondary: #061638;
  --cyan: #00D9FF;
  --blue: #168CFF;
  --purple: #8A2EFF;
  --violet: #B84CFF;
  --white: #FFFFFF;
  --text-gray: #B0BBE0;

  --font-main: 'Cairo', sans-serif;
  --transition-fast: 0.3s ease;
  --transition-slow: 0.8s ease;
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --transition-fast: 0s;
    --transition-slow: 0s;
  }
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-primary);
  color: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
  direction: rtl;
}

body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('../assets/images/background.png');
  background-size: 100% 100%;
  background-position: center;
  background-repeat: no-repeat;
  z-index: -2;
  pointer-events: none;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  object-fit: contain;
}

/* ========================================
   Header
   ======================================== */

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 20px 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 1000;
  background: rgba(2, 10, 36, 0.8);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0, 217, 255, 0.1);
  transition: var(--transition-fast);
}

.header.scrolled {
  padding: 15px 5%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.logo {
  font-size: 24px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-img {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.logo-img img {
  width: 220px;
  max-width: 100%;
  height: auto;
  object-fit: contain;
}

.nav-links {
  display: flex;
  gap: 30px;
}

.nav-links a {
  font-weight: 600;
  transition: var(--transition-fast);
  position: relative;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--cyan);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background: var(--cyan);
  transition: var(--transition-fast);
  box-shadow: 0 0 10px var(--cyan);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

/* ========================================
   Buttons
   ======================================== */

.btn-primary {
  background: linear-gradient(90deg, var(--blue), var(--purple));
  color: var(--white);
  padding: 12px 25px;
  border-radius: 8px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: var(--transition-fast);
  box-shadow: 0 4px 15px rgba(138, 46, 255, 0.3);
  font-family: inherit;
  font-size: 16px;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(138, 46, 255, 0.5);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  padding: 12px 25px;
  border-radius: 8px;
  font-weight: 600;
  border: 1px solid var(--cyan);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: var(--transition-fast);
  font-family: inherit;
  font-size: 16px;
}

.btn-outline:hover {
  background: rgba(0, 217, 255, 0.1);
  box-shadow: 0 0 15px rgba(0, 217, 255, 0.3);
}

/* ========================================
   Mobile Menu
   ======================================== */

.hamburger {
  display: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  z-index: 1001;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: var(--white);
  transition: var(--transition-fast);
  border-radius: 2px;
}

/* ========================================
   Sections
   ======================================== */

section {
  padding: 120px 5% 60px;
}

.section-title {
  text-align: center;
  margin-bottom: 60px;
}

.section-title h2 {
  font-size: 40px;
  font-weight: 800;
  margin-bottom: 15px;
}

.section-title h2 .highlight {
  color: var(--cyan);
  text-shadow: 0 0 15px rgba(0, 217, 255, 0.4);
}

.section-title h2 .highlight-purple {
  color: var(--purple);
  text-shadow: 0 0 15px rgba(138, 46, 255, 0.4);
}

.section-title p {
  color: var(--text-gray);
  max-width: 600px;
  margin: 0 auto;
  font-size: 18px;
}

/* ========================================
   Glass Card
   ======================================== */

.glass-card {
  background: rgba(6, 22, 56, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  padding: 30px;
  transition: var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.05),
    transparent
  );
  transition: 0.5s;
}

.glass-card:hover::before {
  left: 100%;
}

.glass-card:hover {
  border-color: rgba(0, 217, 255, 0.3);
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.3),
    inset 0 0 20px rgba(0, 217, 255, 0.05);
  transform: translateY(-5px);
}

/* ========================================
   Neon Glow Elements
   ======================================== */

.neon-border {
  border: 1px solid var(--cyan);
  box-shadow:
    0 0 10px rgba(0, 217, 255, 0.3),
    inset 0 0 10px rgba(0, 217, 255, 0.2);
}

.neon-border-purple {
  border: 1px solid var(--violet);
  box-shadow:
    0 0 10px rgba(184, 76, 255, 0.3),
    inset 0 0 10px rgba(184, 76, 255, 0.2);
}

/* ========================================
   Forms
   ======================================== */

.form-group {
  margin-bottom: 20px;
}

.form-control {
  width: 100%;
  padding: 15px;
  background: rgba(6, 22, 56, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: var(--white);
  font-family: inherit;
  font-size: 16px;
  transition: var(--transition-fast);
}

.form-control:focus {
  outline: none;
  border-color: var(--cyan);
  box-shadow: 0 0 10px rgba(0, 217, 255, 0.2);
}

.form-control::placeholder {
  color: var(--text-gray);
}

select.form-control {
  appearance: none;
  background-image: url('data:image/svg+xml;utf8,<svg fill="%23FFFFFF" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/><path d="M0 0h24v24H0z" fill="none"/></svg>');
  background-repeat: no-repeat;
  background-position-x: 10px;
  background-position-y: center;
}

/* /* ========================================
   Date Input - تاريخ التسليم
   ======================================== */

#proj-date {
  width: 100%;
  padding: 15px;
  background: rgba(6, 22, 56, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: var(--white);
  font-family: inherit;
  font-size: 16px;
  cursor: pointer;
  transition: var(--transition-fast);
}

#proj-date:focus {
  outline: none;
  border-color: var(--cyan);
  box-shadow: 0 0 10px rgba(0, 217, 255, 0.2);
}

/* إخفاء سنة / شهر / يوم عندما يكون الحقل فارغًا */
#proj-date:not(.has-date)::-webkit-datetime-edit,
#proj-date:not(.has-date)::-webkit-datetime-edit-fields-wrapper,
#proj-date:not(.has-date)::-webkit-datetime-edit-text,
#proj-date:not(.has-date)::-webkit-datetime-edit-month-field,
#proj-date:not(.has-date)::-webkit-datetime-edit-day-field,
#proj-date:not(.has-date)::-webkit-datetime-edit-year-field {
  color: transparent;
  opacity: 0;
}

/* إظهار التاريخ بعد اختياره */
#proj-date.has-date::-webkit-datetime-edit,
#proj-date.has-date::-webkit-datetime-edit-fields-wrapper,
#proj-date.has-date::-webkit-datetime-edit-text,
#proj-date.has-date::-webkit-datetime-edit-month-field,
#proj-date.has-date::-webkit-datetime-edit-day-field,
#proj-date.has-date::-webkit-datetime-edit-year-field {
  color: var(--white);
  opacity: 1;
}

/* زر التقويم */
#proj-date::-webkit-calendar-picker-indicator {
  cursor: pointer;
  opacity: 1;
}

/* ========================================
   Error & Success Messages
   ======================================== */

.error-msg {
  color: #ff4d4d;
  font-size: 14px;
  margin-top: 5px;
  display: none;
}

.success-msg {
  background: rgba(46, 204, 113, 0.2);
  border: 1px solid #2ecc71;
  color: #2ecc71;
  padding: 15px;
  border-radius: 8px;
  margin-top: 20px;
  display: none;
  text-align: center;
}

/* ========================================
   Footer
   ======================================== */

.footer {
  background: var(--bg-secondary);
  padding: 20px 5%;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  margin-top: auto;
}

.footer-bottom {
  text-align: center;
  color: var(--text-gray);
  font-size: 14px;
}

/* ========================================
   Service Cards Links
   ======================================== */

.service-link {
  display: block;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  height: 100%;
}

.service-link .glass-card {
  transition: var(--transition-fast);
  height: 100%;
}

.service-link:hover .glass-card {
  transform: translateY(-5px);
  border-color: rgba(0, 217, 255, 0.5);
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.3),
    0 0 15px rgba(0, 217, 255, 0.2),
    inset 0 0 15px rgba(0, 217, 255, 0.1);
  background: rgba(6, 22, 56, 0.8);
}