:root {
    --primary-green: #2d5a5e; 
    --emerald-green: #0a8a5f; 
    --white: #ffffff;
    --transition: all 0.3s ease;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body { 
    font-family: 'Cairo', sans-serif; 
    background: #ffffff; 
    color: #333; 
    text-align: center; 
    line-height: 1.6;
}

.container { width: 92%; max-width: 1200px; margin: 0 auto; }
ul, li { list-style: none !important; }
a { text-decoration: none; }

/* --- HEADER & NAVIGATION --- */
header { 
    background: var(--white); 
    padding: 12px 0; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.05); 
    position: sticky; 
    top: 0; 
    z-index: 2000; 
}

.header-flex { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.logo-area { display: flex; align-items: center; gap: 12px; }
.main-logo { height: 45px; }
.site-name { font-size: 20px; font-weight: 800; color: var(--primary-green); }

.nav-wrapper { display: flex; flex: 1; justify-content: center; }
.nav-links { display: flex; gap: 20px; align-items: center; }
.nav-links li a { font-weight: 700; color: #444; font-size: 15px; transition: var(--transition); }
.nav-links li a:hover, .nav-links li a.active { color: var(--emerald-green); }

.header-left { display: flex; align-items: center; gap: 15px; }
.btn-lang-outline {
    border: 1.5px solid var(--primary-green);
    color: var(--primary-green);
    padding: 6px 16px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 14px;
    transition: var(--transition);
}
.btn-lang-outline:hover { background: var(--primary-green); color: var(--white); }

.menu-toggle { display: none; font-size: 24px; cursor: pointer; color: var(--primary-green); }

/* --- DROPDOWN --- */
.dropdown { position: relative; }
.dropbtn {
    background: transparent; border: none; cursor: pointer;
    font-family: 'Cairo'; font-weight: 700; font-size: 15px;
    display: flex; align-items: center; gap: 8px; color: #444;
}
.dropdown-content { 
    display: none; position: absolute; top: 100%; right: 0; /* Changed left to right for RTL */
    background-color: white; min-width: 230px; 
    box-shadow: 0 10px 25px rgba(0,0,0,0.1); border-radius: 8px; padding: 10px 0;
}
.dropdown-content li a { padding: 12px 20px; display: block; text-align: right; } /* text-align: right */
.dropdown-content li a:hover { background: #f8fbfb; color: var(--emerald-green); }
@media (min-width: 993px) { .dropdown:hover .dropdown-content { display: block; } }

/* --- ORG CHART SECTION --- */
.board-page { padding: 60px 0; }
.board-intro h1 { color: var(--primary-green); margin-bottom: 10px; }
.board-intro p { color: #666; margin-bottom: 40px; }

.org-chart { display: flex; flex-direction: column; align-items: center; }
.board-card { padding: 25px; border-radius: 12px; width: 280px; border: 1.5px solid transparent; transition: var(--transition); }
.board-card:hover { transform: translateY(-5px); box-shadow: 0 5px 15px rgba(0,0,0,0.05); }

.member-name { font-size: 18px; font-weight: 700; margin-bottom: 5px; }
.member-role { font-size: 14px; opacity: 0.9; }

.connector-v { width: 2px; height: 30px; background-color: #e0e0e0; }

.members-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
    padding-top: 30px; border-top: 2px solid #e0e0e0; position: relative;
}

.chairman { background-color: #f0f0ff; border-color: #d8d8f7; color: #5858a8; }
.vice-chairman { background-color: #e8f5f0; border-color: #cce5dc; color: #1d7051; }
.member { background-color: #eaf4fb; border-color: #d1e4f2; color: #1a5e8a; }

/* --- FOOTER --- */
.main-footer {
    background: var(--primary-green);
    color: var(--white);
    padding: 60px 0 20px;
    margin-top: 80px;
    text-align: right; /* Changed for RTL */
}

.footer-grid { 
    display: grid; 
    grid-template-columns: 2fr 1fr 1fr; 
    gap: 40px; 
    align-items: start;
}

.footer-logo { height: 60px; margin-bottom: 25px; filter: brightness(0) invert(1); }

.org-details { display: flex; flex-direction: column; gap: 12px; }
.detail-item { display: flex; align-items: flex-start; gap: 15px; }
.detail-label { font-weight: 800; color: var(--white); min-width: 150px; font-size: 14px; }

.footer-links h3, .footer-social h3 {
    margin-bottom: 25px; font-size: 18px; font-weight: 700;
    position: relative; padding-bottom: 10px;
}
.footer-links h3::after, .footer-social h3::after {
    content: ''; position: absolute; right: 0; bottom: 0; /* Changed left to right */
    width: 40px; height: 2px; background: var(--emerald-green);
}

.footer-links ul li { margin-bottom: 12px; }
.footer-links ul li a { color: #bdc3c7; font-size: 15px; transition: var(--transition); }
.footer-links ul li a:hover { color: var(--white); padding-right: 5px; } /* padding-right */

.social-icons { display: flex; gap: 15px; }
.social-icons a { 
    width: 40px; height: 40px; background: rgba(255,255,255,0.1); 
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%; color: var(--white); transition: var(--transition);
}
.social-icons a:hover { background: var(--emerald-green); }

.footer-bottom {
    text-align: center; margin-top: 40px; padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1); font-size: 14px; color: #bdc3c7;
}

/* --- RESPONSIVE FIXES --- */
@media (max-width: 992px) {
    .menu-toggle { display: block; }
    .site-name { display: none; }
    .nav-wrapper { 
        display: none; position: absolute; top: 100%; left: 0; width: 100%; 
        background: white; flex-direction: column; padding: 20px; box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    }
    .nav-wrapper.active { display: flex; }
    .nav-links { flex-direction: column; width: 100%; gap: 15px; align-items: flex-start; }
    .dropdown-content { position: static; box-shadow: none; display: none; padding-right: 20px; width: 100%; }
    .dropdown.is-open .dropdown-content { display: block; }
    
    .members-grid { grid-template-columns: 1fr; border-top: none; padding-top: 0; }
    .members-grid .board-card { margin-top: 20px; margin-left: auto; margin-right: auto; }
}

@media (max-width: 768px) {
    .footer-grid { grid-template-columns: 1fr; text-align: center; }
    .footer-brand { display: flex; flex-direction: column; align-items: center; }
    .footer-links h3::after, .footer-social h3::after { left: 50%; transform: translateX(-50%); }
    .detail-item { flex-direction: column; gap: 5px; align-items: center; }
    .social-icons { justify-content: center; }
}