/* استدعاء خط عربي احترافي من جوجل */
@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;700;800&display=swap');

:root {
    --primary-blue: #1A365D; /* أزرق داكن واحترافي */
    --primary-green: #2ecc71; /* أخضر حيوي للمشاركة */
    --light-bg: #f8f9fa;
    --text-dark: #2d3748;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Tajawal', sans-serif;
}

body {
    direction: rtl;
    background-color: var(--light-bg);
    color: var(--text-dark);
    line-height: 1.6;
}

/* الترويسة القائمة العلوية */
header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 1rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary-blue);
}

.logo span {
    color: var(--primary-green);
}

nav a {
    text-decoration: none;
    color: var(--text-dark);
    margin-right: 1.5rem;
    font-weight: 500;
    transition: color 0.3s;
}

nav a:hover {
    color: var(--primary-green);
}

.btn-participate {
    background-color: var(--primary-green);
    color: white;
    padding: 0.6rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    transition: background 0.3s;
}

.btn-participate:hover {
    background-color: #27ae60;
}

/* القسم الرئيسي (الواجهة) */
.hero {
    background: linear-gradient(135deg, var(--primary-blue), #2c5282);
    color: white;
    text-align: center;
    padding: 6rem 5%;
}

.hero h1 {
    font-size: 2.8rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0.9;
}

.hero .btn-participate {
    font-size: 1.3rem;
    padding: 0.8rem 2.5rem;
    box-shadow: 0 4px 15px rgba(46, 204, 113, 0.4);
}

/* الفوتر */
footer {
    background-color: var(--primary-blue);
    color: white;
    text-align: center;
    padding: 2rem;
    margin-top: auto;
}

/* --- إعدادات التوافق مع شاشات الجوال واللوحيات --- */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: center;
        padding: 15px 10px;
        gap: 15px;
    }
    
    .logo {
        font-size: 1.6rem;
        text-align: center;
        width: 100%;
        margin-bottom: 5px;
    }
    
    nav {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
        width: 100%;
    }
    
    nav a {
        margin: 0; /* إلغاء التباعد الافتراضي */
        font-size: 0.9rem;
        background-color: #f1f5f9; /* لون خلفية خفيف للزر */
        padding: 6px 12px;
        border-radius: 20px;
        border: 1px solid #e2e8f0;
    }
    
    nav a:hover {
        background-color: var(--primary-green);
        color: white;
    }
    
    .btn-participate {
        width: 90%;
        text-align: center;
        margin-top: 10px;
    }

    .hero {
        padding: 4rem 5%;
    }

    .hero h1 {
        font-size: 2rem;
    }
    
    .certificate-wrapper {
        width: 100% !important;
        padding: 20px !important;
        border-width: 8px !important;
    }
    
    .cert-header {
        font-size: 1.8rem !important;
    }
    
    .cert-body {
        font-size: 1.2rem !important;
    }
}