/* =======================
   إعدادات عامة ومتغيرات فضائية
======================== */
:root {
    --space-blue: #040c18;
    --space-dark: #020a15;
    --accent-orange: #FF6F00;
    --accent-orange-light: #FF8F33;
    --glow-blue: #00aaff;
    --glow-blue-light: #33BBFF;
    --accent-gold: #cba55b;
    --accent-gold-light: #D9C08B;
    --white: #FFFFFF;
    --text-color: #E0E0E0;
    --text-light: #F5F5F5;
    --font-family: 'Cairo', sans-serif;
    --box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    --transition: all 0.3s ease-in-out;
}

/* إعادة تعيين أساسية */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background-color: var(--space-dark);
    color: var(--text-color);
    line-height: 1.7;
    direction: rtl;
    overflow-x: hidden;
}

/* =======================
        خلفية النجوم المتحركة
======================== */
@keyframes animate-stars {
    from {
        transform: translateY(0);
    }
    to {
        transform: translateY(-2000px);
    }
}

.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    background-repeat: repeat;
    background-position: center;
}

#stars1 {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Ccircle cx='50' cy='50' r='0.5' fill='white'/%3E%3C/svg%3E");
    background-size: 200px 200px;
    animation: animate-stars 150s linear infinite;
}

#stars2 {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Ccircle cx='50' cy='50' r='0.7' fill='white'/%3E%3C/svg%3E");
    background-size: 300px 300px;
    animation: animate-stars 100s linear infinite;
}

#stars3 {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Ccircle cx='50' cy='50' r='1' fill='white'/%3E%3C/svg%3E");
    background-size: 400px 400px;
    animation: animate-stars 75s linear infinite;
}


.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px;
    position: relative;
    z-index: 2;
}

/* =======================
        تنسيق الهيدر الجديد
======================== */
header {
    background: rgba(4, 12, 24, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 170, 255, 0.2);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 100px;
    transition: var(--transition);
    filter: drop-shadow(0 0 10px rgba(203, 165, 91, 0.7));
}

.logo img:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 0 15px rgba(203, 165, 91, 0.9));
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 25px;
}

.nav-links a {
    color: var(--text-light);
    font-weight: 600;
    font-size: 1.1rem;
    padding: 8px 15px;
    border-radius: 5px;
    transition: var(--transition);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    right: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-orange);
    transition: var(--transition);
}

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

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent-orange);
    text-shadow: 0 0 10px var(--accent-orange);
}

.nav-button {
    background-color: var(--accent-orange);
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(255, 111, 0, 0.3);
}

.nav-button:hover {
    background-color: var(--accent-orange-light);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(255, 111, 0, 0.4);
}

.mobile-menu-button {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
}

/* =======================
      القسم الرئيسي (Hero)
======================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    background: transparent; /* جعلناه شفافاً لتظهر الخلفية المتحركة */
}

.hero-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 0;
}

.hero h1 {
    font-size: 4rem;
    font-weight: 900;
    line-height: 1.2;
    margin-bottom: 20px;
    color: var(--white);
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    animation: title-glow 4s infinite ease-in-out;
}

.hero .subtitle {
    font-size: 1.4rem;
    margin-bottom: 40px;
    opacity: 0.9;
    color: var(--text-light);
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
}

.btn {
    padding: 15px 35px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-primary {
    background-color: var(--accent-orange);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 111, 0, 0.4);
}

.btn-primary:hover {
    background-color: var(--accent-orange-light);
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(255, 111, 0, 0.5);
}

.btn-secondary {
    background-color: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-5px);
    border-color: var(--accent-orange);
    color: var(--accent-orange);
}

.hero-scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--white);
    font-size: 1.5rem;
    animation: bounce 2s infinite;
    cursor: pointer;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {transform: translateY(0) translateX(-50%);}
    40% {transform: translateY(-20px) translateX(-50%);}
    60% {transform: translateY(-10px) translateX(-50%);}
}

/* =======================
         قسم من نحن
======================== */
.about-us {
    padding: 120px 0;
    background-color: var(--space-dark);
    position: relative;
}

.about-content {
    position: relative;
    z-index: 2;
}

.about-us p {
    font-size: 1.3rem;
    max-width: 900px;
    margin: 0 auto 50px;
    text-align: center;
    line-height: 2;
    color: var(--text-light);
}

/* =======================
         قسم قيمنا
======================== */
.values-section {
    padding: 120px 0;
    background: linear-gradient(to bottom, var(--space-dark) 0%, var(--space-blue) 100%);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-top: 60px;
}

.card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 50px 30px;
    text-align: center;
    border-radius: 15px;
    border: 1px solid rgba(0, 170, 255, 0.2);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 111, 0, 0.1) 0%, rgba(0, 170, 255, 0.1) 100%);
    z-index: -1;
    opacity: 0;
    transition: var(--transition);
}

.card:hover::before {
    opacity: 1;
}

.card-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    transition: var(--transition);
}

.card:hover .card-icon {
    background: var(--accent-orange);
    transform: rotateY(180deg);
}

.card i {
    font-size: 2.5rem;
    color: var(--accent-orange);
    transition: var(--transition);
}

.card:hover i {
    color: white;
}

.card h3 {
    margin-bottom: 20px;
    font-size: 1.6rem;
    position: relative;
    padding-bottom: 15px;
}

.card h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 2px;
    background-color: var(--accent-orange);
    transition: var(--transition);
}

.card:hover h3::after {
    width: 80px;
    background-color: var(--white);
}

.card p {
    font-size: 1.1rem;
    margin-bottom: 25px;
    color: var(--text-light);
}

.card-link {
    color: var(--accent-orange);
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: var(--transition);
}

.card:hover .card-link {
    color: var(--white);
}

/* =======================
        قسم خدماتنا
======================== */
.services-section {
    padding: 120px 0;
    background-color: var(--space-dark);
    position: relative;
}

/* =======================
        قسم الفوتر
======================== */
footer {
    background: linear-gradient(to bottom, var(--space-dark) 0%, #01050a 100%);
    padding: 80px 0 0 0;
    position: relative;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 50px;
    margin-bottom: 60px;
}

.footer-info {
    max-width: 400px;
}

.footer-logo img {
    height: 100px;
    margin-bottom: 20px;
    filter: drop-shadow(0 0 10px rgba(203, 165, 91, 0.7));
}

.footer-contact p {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 15px 0;
}

.footer-links h3,
.footer-social h3 {
    color: var(--white);
    font-size: 1.5rem;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}

.footer-links h3::after,
.footer-social h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 50px;
    height: 2px;
    background-color: var(--accent-orange);
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 15px;
}

.footer-links a {
    color: var(--text-color);
    transition: var(--transition);
    display: inline-block;
}

.footer-links a:hover {
    color: var(--accent-orange);
    transform: translateX(-10px);
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-links a {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.3rem;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--accent-orange);
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(255, 111, 0, 0.4);
}

.copyright-bar {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 20px 0;
    text-align: center;
}

.copyright {
    opacity: 0.7;
    font-size: 0.9rem;
}

/* =======================
   تأثيرات الحركة عند التمرير
======================== */
.section-title {
    text-align: center;
    margin-bottom: 80px;
}

.section-title h2 {
    font-size: 2.8rem;
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.section-title p {
    font-size: 1.2rem;
    color: var(--text-light);
    max-width: 700px;
    margin: 0 auto;
}

.title-decoration {
    width: 80px;
    height: 4px;
    background: linear-gradient(to right, var(--accent-orange), var(--glow-blue));
    margin: 20px auto;
    border-radius: 2px;
}

.fade-in-element {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-element.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* =======================
   تنسيقات للهواتف (Responsive)
======================== */
@media (max-width: 1200px) {
    .container {
        padding: 0 40px;
    }
    
    .hero h1 {
        font-size: 3.5rem;
    }
}

@media (max-width: 992px) {
    .main-nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 400px;
        height: 100vh;
        background-color: var(--space-dark);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 50px;
        transition: var(--transition);
        z-index: 1000;
        padding: 80px 30px 30px;
        box-shadow: -5px 0 30px rgba(0, 0, 0, 0.3);
    }
    
    .main-nav.active {
        right: 0;
    }
    
    .nav-links {
        flex-direction: column;
        align-items: center;
        gap: 30px;
    }
    
    .mobile-menu-button {
        display: block;
        z-index: 1001;
    }
    
    .hero h1 {
        font-size: 3rem;
    }
    
    .hero .subtitle {
        font-size: 1.2rem;
    }
    
    .btn {
        padding: 12px 25px;
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 30px;
    }
    
    .logo img {
        height: 80px;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 15px;
    }
    
    .section-title h2 {
        font-size: 2.2rem;
    }
    
    .about-us p {
        font-size: 1.1rem;
    }
}

@media (max-width: 576px) {
    .container {
        padding: 0 20px;
    }
    
    .hero h1 {
        font-size: 2.2rem;
    }
    
    .hero .subtitle {
        font-size: 1.1rem;
    }
    
    .section-title h2 {
        font-size: 2rem;
    }
    
    .card {
        padding: 40px 20px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}