/* Base Styles & Variables */
:root {
    --primary-color: #ce1126; /* Jordan Deep Red */
    --secondary-color: #007a3d; /* Jordan Green */
    --dark-color: #000000;
    --light-color: #ffffff;
    --gold-color: #d4af37;
    --bg-light: #f8f9fa;
    --text-main: #333333;
    --text-muted: #666666;
    --shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
    --container-width: 1200px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-main);
    background-color: var(--light-color);
    overflow-x: hidden;
}

/* Arabic Font Overrides */
html[lang="ar"] body {
    font-family: 'Cairo', sans-serif;
}

ul {
    list-style: none;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 80px 0;
}

.bg-light { background-color: var(--bg-light); }
.bg-dark { background-color: var(--dark-color); }
.text-white { color: var(--light-color); }

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.underline {
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    margin: 0 auto;
}

.underline.gold { background-color: var(--gold-color); }

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    text-align: center;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: #a00d1e;
    transform: translateY(-3px);
}

.btn-outline {
    background-color: transparent;
    border-color: white;
    color: white;
}

.btn-outline:hover {
    background-color: white;
    color: var(--primary-color);
}

.btn-block { width: 100%; }

/* Scroll to Top */
#scrollToTop {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    z-index: 1000;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

html[lang="ar"] #scrollToTop {
    right: auto;
    left: 30px;
}

#scrollToTop:hover {
    background-color: var(--dark-color);
    transform: scale(1.1);
}

/* Header & Navbar */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background-color: transparent;
    padding: 20px 0;
    transition: var(--transition);
}

.header.scrolled {
    background-color: white;
    box-shadow: var(--shadow);
    padding: 10px 0;
}

.header.scrolled .school-name,
.header.scrolled .nav-link {
    color: var(--dark-color);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-placeholder {
    width: 45px;
    height: 45px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.school-name {
    font-weight: 700;
    font-size: 1.2rem;
    color: white;
    max-width: 300px;
    line-height: 1.2;
}

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

.nav-link {
    color: white;
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--gold-color);
    transition: var(--transition);
}

html[lang="ar"] .nav-link::after {
    left: auto;
    right: 0;
}

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

.nav-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn-lang {
    background-color: rgba(255, 255, 255, 0.2);
    border: 1px solid white;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: inherit;
    font-weight: 600;
}

.header.scrolled .btn-lang {
    color: var(--primary-color);
    border-color: var(--primary-color);
    background-color: transparent;
}

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

.header.scrolled .mobile-menu-btn { color: var(--dark-color); }

/* Hero Section */
.hero {
    height: 100vh;
    background: url('assets/img/gallery/ach_0.jpg') center/cover no-repeat;
    display: flex;
    align-items: center;
    position: relative;
    color: white;
    padding-top: 80px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.7), rgba(0,0,0,0.4));
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 800px;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.1;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 35px;
    opacity: 0.9;
}

.hero-btns {
    display: flex;
    gap: 20px;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-text p {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: var(--text-muted);
}

.about-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.feature-card {
    background-color: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
    border-left: 5px solid var(--primary-color);
    transition: var(--transition);
}

html[lang="ar"] .feature-card {
    border-left: none;
    border-right: 5px solid var(--primary-color);
}

.feature-card:hover { transform: translateX(10px); }
html[lang="ar"] .feature-card:hover { transform: translateX(-10px); }

.feature-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
}

.feature-card h3 {
    font-size: 1.2rem;
    font-weight: 600;
}

/* Mission & Vision */
.mv-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.mv-card {
    background-color: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--shadow);
    text-align: center;
    border-bottom: 5px solid var(--primary-color);
}

.mv-card:nth-child(2) { border-bottom-color: var(--secondary-color); }

.icon-box {
    width: 70px;
    height: 70px;
    background-color: var(--bg-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 2rem;
    color: var(--primary-color);
}

.mv-card:nth-child(2) .icon-box { color: var(--secondary-color); }

.mv-card h2 { margin-bottom: 15px; font-size: 1.8rem; }

/* Academics */
.academic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.academic-card {
    background-color: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.academic-card:hover {
    background-color: var(--primary-color);
    color: white;
}

.academic-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    transition: var(--transition);
}

.academic-card:hover i { color: white; }

.academics-info {
    background-color: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--shadow);
}

.check-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.check-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

.check-list li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--secondary-color);
}

/* Achievements */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    text-align: center;
    margin-bottom: 40px;
}

.stat-number {
    display: block;
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--gold-color);
    line-height: 1;
}

.stat-item p {
    font-size: 1.2rem;
    font-weight: 500;
}

.achievements-desc {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.2rem;
    line-height: 1.8;
}

/* Detailed Achievements Grid */
.achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
    align-items: start;
}

.achievement-card {
    background-color: rgba(255, 255, 255, 0.05);
    padding: 30px;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.achievement-card:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-10px);
    border-color: var(--gold-color);
}

.ach-icon {
    font-size: 2.5rem;
    color: var(--gold-color);
    margin-bottom: 20px;
}

.achievement-card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--gold-color);
}

.achievement-card p {
    font-size: 1rem;
    opacity: 0.9;
    line-height: 1.5;
    /* Truncation */
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 15px;
}

.btn-read-more {
    margin-top: 15px;
    padding: 0;
    background-color: transparent;
    color: var(--primary-color);
    border: none;
    cursor: pointer;
    font-weight: bold;
    font-size: 1rem;
    transition: var(--transition);
    text-decoration: underline;
}

.btn-read-more:hover {
    color: var(--gold-color);
}

.achievements-extra .btn-read-more,
.page-achievements-grid .btn-read-more {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-read-more:hover {
    background: var(--gold-color);
    color: var(--dark-color);
}

.achievements-extra .btn-read-more:hover,
.page-achievements-grid .btn-read-more:hover {
    background: var(--primary-color);
    color: white;
}

.gold-text {
    color: var(--gold-color) !important;
}

/* Extra Achievements Section (Light Background) */
.achievements-extra .achievements-grid {
    max-height: 600px;
    overflow-y: auto;
    padding: 20px;
    margin-bottom: 0;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) rgba(0,0,0,0.05);
    border-radius: 15px;
    background: rgba(0, 0, 0, 0.02);
    box-shadow: inset 0 0 15px rgba(0,0,0,0.05);
}

.achievements-extra .achievements-grid::-webkit-scrollbar {
    width: 8px;
}
.achievements-extra .achievements-grid::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.05);
    border-radius: 10px;
}
.achievements-extra .achievements-grid::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

.achievements-extra .achievement-card,
.page-achievements-grid .achievement-card {
    background-color: white;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: var(--shadow);
}
.achievements-extra .achievement-card:hover,
.page-achievements-grid .achievement-card:hover {
    background-color: white;
    border-color: var(--primary-color);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.achievements-extra .achievement-card h3,
.page-achievements-grid .achievement-card h3 {
    color: var(--primary-color);
}
.achievements-extra .ach-icon,
.page-achievements-grid .ach-icon {
    color: var(--primary-color);
}

/* Royal Recognition Styles */
.royal-recognition {
    background-color: var(--primary-color);
    color: var(--light-color);
    text-align: center;
}

.royal-card {
    max-width: 900px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.1);
    padding: 50px;
    border-radius: 20px;
    border: 2px solid var(--gold-color);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.royal-icon {
    font-size: 3.5rem;
    margin-bottom: 25px;
}

.royal-quote {
    font-size: 1.8rem;
    font-style: italic;
    margin-bottom: 30px;
    line-height: 1.4;
    font-family: 'Times New Roman', serif;
}

.royal-quote cite {
    display: block;
    font-size: 1.1rem;
    margin-top: 15px;
    font-style: normal;
    font-weight: bold;
    color: var(--gold-color);
}

.order-honor {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.medal-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.order-honor h3 {
    font-size: 1.5rem;
    color: var(--gold-color);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.order-honor p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Timeline Section */
.timeline-section {
    background-color: var(--light-color);
    color: var(--dark-color);
}

.timeline-section .section-header h2 {
    color: var(--primary-color);
}

.timeline-container {
    position: relative;
    max-width: 1000px;
    margin: 40px auto;
    padding: 20px 0;
}

.timeline-container::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: var(--primary-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    background-color: inherit;
    width: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 25px;
    right: -12px;
    background-color: var(--light-color);
    border: 4px solid var(--primary-color);
    top: 15px;
    border-radius: 50%;
    z-index: 1;
}

.timeline-item:nth-child(even) {
    left: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
}

.timeline-item:nth-child(even)::after {
    left: -12px;
}

.timeline-year {
    font-weight: bold;
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.timeline-content {
    padding: 20px 30px;
    background-color: #f9f9f9;
    position: relative;
    border-radius: 6px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.timeline-content h3 {
    margin-top: 0;
    color: var(--secondary-color);
    font-size: 1.2rem;
}

/* RTL Timeline Adjustments */
html[lang="ar"] .timeline-container::after {
    left: 50%;
}

html[lang="ar"] .timeline-item {
    width: 50%;
}

html[lang="ar"] .timeline-item:nth-child(odd) {
    left: auto;
    right: 0;
}

html[lang="ar"] .timeline-item:nth-child(even) {
    left: 0;
    right: auto;
}

html[lang="ar"] .timeline-item::after {
    right: -12px;
    left: auto;
}

html[lang="ar"] .timeline-item:nth-child(even)::after {
    left: -12px;
    right: auto;
}

@media screen and (max-width: 600px) {
    .timeline-container::after {
        left: 31px;
    }
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }
    .timeline-item::after {
        left: 18px;
    }
    .timeline-item:nth-child(even) {
        left: 0;
    }
    html[lang="ar"] .timeline-container::after {
        left: auto;
        right: 31px;
    }
    html[lang="ar"] .timeline-item {
        padding-right: 70px;
        padding-left: 25px;
    }
    html[lang="ar"] .timeline-item::after {
        right: 18px;
        left: auto;
    }
}

/* Activities */
.activities-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.activity-tag {
    background-color: white;
    padding: 12px 25px;
    border-radius: 50px;
    box-shadow: var(--shadow);
    font-weight: 600;
    color: var(--primary-color);
    border: 1px solid rgba(206, 17, 38, 0.1);
    transition: var(--transition);
}

.activity-tag:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-5px);
}

/* News */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.news-card {
    background-color: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.news-card:hover { transform: translateY(-10px); }

.news-img-placeholder {
    height: 200px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--light-color);
}

.news-body { padding: 25px; }
.news-date { color: var(--primary-color); font-weight: bold; font-size: 0.9rem; margin-bottom: 10px; display: block; }
.news-body h3 { margin-bottom: 15px; font-size: 1.3rem; }
.news-read-more { color: var(--primary-color); font-weight: 700; cursor: pointer; }

/* Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.gallery-item {
    height: 250px;
    border-radius: 15px;
    background: linear-gradient(45deg, #1a1a1a, #444);
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.gallery-item:nth-child(1) { background-image: url('assets/img/gallery/ach_0.jpg'); }
.gallery-item:nth-child(2) { background-image: url('assets/img/gallery/ach_1.jpg'); }
.gallery-item:nth-child(3) { background-image: url('assets/img/gallery/ach_2.jpg'); }
.gallery-item:nth-child(4) { background-image: url('assets/img/gallery/ach_3.jpg'); }
.gallery-item:nth-child(5) { background-image: url('assets/img/gallery/ach_4.jpg'); }
.gallery-item:nth-child(6) { background-image: url('assets/img/gallery/ach_5.jpg'); }

.gallery-item:hover {
    transform: translateY(-5px);
    border-color: var(--gold-color);
}

.gallery-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    color: white;
    text-align: center;
}

.gallery-info h4 {
    margin: 0;
    font-size: 1rem;
    color: var(--gold-color);
}

/* Contact */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 50px;
}

.info-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.info-item i {
    width: 50px;
    height: 50px;
    background-color: white;
    color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: var(--shadow);
}

.info-item h4 { font-size: 1.1rem; margin-bottom: 5px; }

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 40px;
}

.social-links a {
    width: 45px;
    height: 45px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.social-links a:hover {
    background-color: #1877f2;
    transform: translateY(-3px);
}

.facebook-profile-card {
    background-color: white;
    padding: 32px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 26px;
    align-items: center;
}

.facebook-profile-card img {
    width: 120px;
    height: 120px;
    border-radius: 12px;
    object-fit: cover;
    border: 4px solid var(--bg-light);
}

.facebook-profile-card span {
    display: inline-block;
    color: var(--primary-color);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.facebook-profile-card h3 {
    font-size: 1.65rem;
    margin-bottom: 10px;
}

.facebook-profile-card p {
    color: var(--text-muted);
    margin-bottom: 22px;
}

.contact-form-container {
    background-color: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--shadow);
}

.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 500; }
.form-group input, .form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: inherit;
    transition: var(--transition);
}

.form-group input:focus, .form-group textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(206, 17, 38, 0.1);
}

.form-success {
    text-align: center;
    padding: 20px;
}

.form-success i { font-size: 4rem; color: var(--secondary-color); margin-bottom: 20px; }
.hidden { display: none; }

/* Footer */
.footer {
    background-color: var(--dark-color);
    color: white;
    padding: 60px 0 30px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 50px;
    margin-bottom: 40px;
}

.footer-brand h3 { font-size: 1.8rem; margin-bottom: 15px; }
.footer-tagline { opacity: 0.8; font-style: italic; }

.footer-links h4 { margin-bottom: 20px; font-size: 1.2rem; border-bottom: 2px solid var(--primary-color); display: inline-block; }
.footer-links ul li { margin-bottom: 10px; }
.footer-links ul li a:hover { color: var(--gold-color); padding-left: 5px; }
html[lang="ar"] .footer-links ul li a:hover { padding-left: 0; padding-right: 5px; }

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 30px;
    text-align: center;
}

.footer-bottom p { margin-bottom: 10px; opacity: 0.7; font-size: 0.9rem; }
.built-with { font-weight: 600; color: var(--gold-color); opacity: 1 !important; }

/* Animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in.appear {
    opacity: 1;
    transform: translateY(0);
}

/* RTL Specific Adjustments */
html[lang="ar"] {
    direction: rtl;
}

html[lang="ar"] .hero-content {
    text-align: right;
}

html[lang="ar"] .check-list li::before {
    margin-left: 10px;
}

html[lang="ar"] .info-item {
    text-align: right;
}

html[lang="ar"] .footer-links {
    text-align: right;
}

/* Responsive */
@media (max-width: 992px) {
    .hero h1 { font-size: 2.8rem; }
    .about-grid, .mv-grid, .contact-wrapper, .footer-content {
        grid-template-columns: 1fr;
    }
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background-color: white;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
        transition: var(--transition);
        z-index: 1001;
    }

    html[lang="ar"] .nav-links {
        right: auto;
        left: -100%;
        box-shadow: 5px 0 15px rgba(0,0,0,0.1);
    }

    .nav-links.active { right: 0; }
    html[lang="ar"] .nav-links.active { left: 0; }

    .nav-link { color: var(--dark-color); font-size: 1.2rem; }
    .mobile-menu-btn { display: block; z-index: 1002; }
    .nav-actions { z-index: 1002; }

    .check-list { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .hero h1 { font-size: 2.2rem; }
    .hero p { font-size: 1.1rem; }
    .hero-btns { flex-direction: column; }
    .section-header h2 { font-size: 2rem; }
    .facebook-profile-card {
        grid-template-columns: 1fr;
        padding: 24px;
    }
    .facebook-profile-card img {
        width: 96px;
        height: 96px;
    }
}
/* --- Achievement Modal --- */
.modal {
    display: none; /* Hidden by default */
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    justify-content: center;
    align-items: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.active {
    display: flex;
    opacity: 1;
}

.modal-content {
    background-color: white;
    padding: 40px;
    border-radius: 20px;
    max-width: 700px;
    width: 100%;
    position: relative;
    box-shadow: 0 15px 50px rgba(0,0,0,0.3);
    transform: translateY(30px);
    transition: transform 0.3s ease;
    max-height: 90vh;
    overflow-y: auto;
}

.modal.active .modal-content {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 25px;
    color: #999;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s;
    line-height: 1;
}

html[lang="ar"] .close-modal {
    right: auto;
    left: 25px;
}

.close-modal:hover {
    color: var(--primary-color);
}

.modal-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    text-align: center;
}

.modal-date {
    display: block;
    text-align: center;
    font-weight: bold;
    color: #666;
    margin-bottom: 10px;
}

.modal-title {
    color: var(--primary-color);
    text-align: center;
    font-size: 1.8rem;
    margin-bottom: 20px;
}

.modal-body {
    color: #333;
    font-size: 1.1rem;
    line-height: 1.8;
    text-align: justify;
}
