:root {
    --primary-blue: #1a3a5f;
    --secondary-blue: #2c5282;
    --light-blue: #4299e1;
    --white: #ffffff;
    --light-gray: #f7fafc;
    --dark-gray: #2d3748;
    --black: #1a202c;
    --fade-blue: rgba(26, 58, 95, 0.05);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Tajawal', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--white);
    color: var(--dark-gray);
    line-height: 1.6;
    overflow-x: hidden;
}

body.rtl {
    direction: rtl;
    text-align: right;
}

body.rtl .nav-container {
    flex-direction: row-reverse;
}

body.rtl .nav-links li {
    margin-left: 0;
    margin-right: 30px;
}

body.rtl .mobile-menu {
    margin-left: 0;
    margin-right: auto;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
}

/* Header & Hero */
header.hero-header {
    background: linear-gradient(rgba(26, 58, 95, 0.85), rgba(44, 82, 130, 0.85)),
                url('/wazir/img/gb.jpg') no-repeat center center;
    background-size: cover;
    color: var(--white);
    height: 480px;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}


header.hero-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top left, rgba(255,255,255,0.15), transparent 55%);
    opacity: 0.9;
}

.hero-inner {
    position: relative;
    z-index: 1;
}

.hero-content {
    display: flex;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;
}

.profile-img {
    width: 210px;
    height: 210px;
    border-radius: 50%;
    border: 4px solid rgba(255, 255, 255, 0.4);
    background-color: var(--light-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.profile-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-text {
    flex: 1;
    min-width: 260px;
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.85rem;
    background: rgba(255,255,255,0.12);
    margin-bottom: 12px;
}

.hero-tag i {
    font-size: 0.9rem;
}

h1 {
    font-size: 2.8rem;
    margin-bottom: 8px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    letter-spacing: 0.03em;
}

.position {
    font-size: 1.4rem;
    margin-bottom: 18px;
    color: #e2f0ff;
    font-weight: 500;
}

.tagline {
    font-size: 1.1rem;
    margin-bottom: 24px;
    opacity: 0.95;
    max-width: 520px;
}

.header-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    background: var(--light-blue);
    color: var(--white);
    border-radius: 30px;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition);
    border: 2px solid var(--light-blue);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -40%;
    width: 40%;
    height: 100%;
    background: linear-gradient(120deg, rgba(255,255,255,0.4), transparent);
    transform: skewX(-25deg);
    transition: transform 0.4s ease;
}

.btn:hover::after {
    transform: translateX(260%) skewX(-25deg);
}

.btn:hover {
    background: transparent;
    color: var(--light-blue);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.btn-outline {
    background: transparent;
    border: 2px solid rgba(255,255,255,0.85);
    color: var(--white);
}

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

/* Navigation */
nav {
    background: rgba(255,255,255,0.98);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 0;
    z-index: 999;
    backdrop-filter: blur(12px);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
}

.logo {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-blue);
    text-decoration: none;
    letter-spacing: 0.04em;
}

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

.nav-links li {
    margin-left: 26px;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark-gray);
    font-weight: 500;
    font-size: 0.98rem;
    transition: var(--transition);
    position: relative;
    padding-bottom: 4px;
}

.nav-links a:hover {
    color: var(--primary-blue);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--light-blue), var(--secondary-blue));
    transition: var(--transition);
}

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

.mobile-menu {
    display: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: var(--primary-blue);
}

/* Sections */
section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

.section-title h2 {
    font-size: 2rem;
    color: var(--primary-blue);
    display: inline-block;
    padding-bottom: 8px;
    position: relative;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, var(--light-blue), var(--secondary-blue));
    border-radius: 999px;
}

.section-subtitle {
    margin-top: 12px;
    font-size: 0.98rem;
    color: #718096;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

/* About Section */
.about {
    background-color: var(--light-gray);
    position: relative;
    overflow: hidden;
}

.about::before {
    content: '';
    position: absolute;
    top: -40px;
    right: -80px;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: var(--fade-blue);
}

.about-content {
    display: flex;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;
}

.about-text {
    flex: 1.2;
    min-width: 260px;
}

.about-text h3 {
    font-size: 1.4rem;
    margin-bottom: 16px;
    color: var(--primary-blue);
}

.about-text p {
    margin-bottom: 12px;
    color: #4a5568;
}

.personal-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 18px;
    margin-top: 24px;
}

.info-item {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(255,255,255,0.9);
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

body.rtl .info-item {
    flex-direction: row-reverse;
}

.info-icon {
    width: 40px;
    height: 40px;
    background: var(--primary-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    color: white;
    flex-shrink: 0;
}

body.rtl .info-icon {
    margin-right: 0;
    margin-left: 12px;
}

.info-content h4 {
    font-size: 0.9rem;
    color: var(--dark-gray);
    margin-bottom: 4px;
}

.info-content p {
    font-size: 0.9rem;
    color: #4a5568;
}

.about-image {
    flex: 1;
    text-align: center;
    min-width: 260px;
}

.about-image img {
    width: 100%;
    max-width: 380px;
    height: 280px;
    object-fit: cover;
    border-radius: 14px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.18);
}

/* Education Section */
.education {
    background: linear-gradient(rgba(26, 58, 95, 0.94), rgba(44, 82, 130, 0.96)), url('/wazir/img/George-Bouchkian.jpg') no-repeat center center;
    background-size: cover;
    color: var(--white);
    position: relative;
}

.education .section-title h2 {
    color: var(--white);
}

.education .section-subtitle {
    color: rgba(255,255,255,0.85);
}

.education .section-title h2::after {
    background: var(--light-blue);
}

.timeline {
    position: relative;
    max-width: 860px;
    margin: 0 auto;
}

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

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
}

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

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

.timeline-content {
    padding: 18px 20px;
    background-color: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
    border-left: 4px solid var(--light-blue);
    backdrop-filter: blur(10px);
}

.timeline-content h3 {
    margin-bottom: 6px;
    color: var(--white);
    font-size: 1.05rem;
}

.timeline-content p {
    margin-bottom: 3px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
}

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

.timeline-item:nth-child(odd)::after {
    right: -9px;
}

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

/* Companies Section */
.companies {
    background-color: var(--light-gray);
    position: relative;
    overflow: hidden;
}

.companies::before {
    content: '';
    position: absolute;
    bottom: -60px;
    left: -60px;
    width: 180px;
    height: 180px;
    background: var(--fade-blue);
    border-radius: 50%;
}

.companies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 26px;
}

.company-card {
    background: var(--white);
    border-radius: 14px;
    padding: 24px 22px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
    transition: var(--transition);
    border-top: 4px solid var(--light-blue);
    text-align: center;
}

.company-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.12);
}

.company-icon {
    font-size: 2.2rem;
    color: var(--light-blue);
    margin-bottom: 12px;
}

.company-card h3 {
    font-size: 1.1rem;
    margin-bottom: 6px;
    color: var(--primary-blue);
}

.company-card p {
    font-size: 0.95rem;
    color: #4a5568;
}

/* Memberships Section */
.memberships {
    background-color: var(--white);
}

.memberships-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
}

.membership-item {
    background: var(--light-gray);
    padding: 18px 16px;
    border-radius: 10px;
    text-align: center;
    transition: var(--transition);
    border-left: 4px solid var(--primary-blue);
    font-size: 0.95rem;
    color: #2d3748;
    box-shadow: 0 6px 16px rgba(0,0,0,0.04);
}

.membership-item:hover {
    background: var(--primary-blue);
    color: var(--white);
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(0,0,0,0.15);
}

.membership-item h3 {
    font-size: 1rem;
    margin-bottom: 4px;
    color: inherit;
}

/* Languages Section */
.languages {
    background-color: var(--light-gray);
    position: relative;
    overflow: hidden;
}

.languages::before {
    content: '';
    position: absolute;
    top: -40px;
    right: -40px;
    width: 140px;
    height: 140px;
    background: var(--fade-blue);
    border-radius: 50%;
}

.languages-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 22px;
}

.language-item {
    text-align: center;
    padding: 18px 16px;
    background: var(--white);
    border-radius: 14px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
    width: 150px;
    transition: var(--transition);
}

.language-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 14px 26px rgba(0, 0, 0, 0.12);
}

.language-flag {
    font-size: 2rem;
    margin-bottom: 10px;
}

.language-name {
    font-size: 1rem;
    font-weight: 500;
    color: var(--primary-blue);
}

/* Contact Section */
.contact {
    background-color: var(--white);
}

.contact-container {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

.contact-info {
    flex: 1;
    min-width: 260px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 18px;
}

body.rtl .contact-item {
    flex-direction: row-reverse;
}

.contact-icon {
    font-size: 1.4rem;
    color: var(--light-blue);
    margin-right: 14px;
    margin-top: 4px;
}

body.rtl .contact-icon {
    margin-right: 0;
    margin-left: 14px;
}

.contact-details h3 {
    font-size: 1.05rem;
    margin-bottom: 4px;
    color: var(--primary-blue);
}

.contact-details p {
    font-size: 0.95rem;
    color: #4a5568;
}

.contact-form {
    flex: 1;
    min-width: 260px;
}

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

.form-control {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d2d6dc;
    border-radius: 6px;
    font-size: 0.95rem;
    transition: var(--transition);
    background-color: #fdfdfd;
}

.form-control:focus {
    border-color: var(--light-blue);
    outline: none;
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.2);
}

textarea.form-control {
    min-height: 140px;
    resize: vertical;
}

/* Footer */
footer {
    background: var(--primary-blue);
    color: var(--white);
    padding: 40px 0 18px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
    margin-bottom: 26px;
}

.footer-logo {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.footer-links a {
    color: var(--white);
    text-decoration: none;
    font-size: 0.95rem;
    opacity: 0.9;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--light-blue);
}

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

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    color: var(--white);
    text-decoration: none;
    transition: var(--transition);
    font-size: 0.95rem;
}

.social-link:hover {
    background: var(--light-blue);
    transform: translateY(-4px);
}

.copyright {
    text-align: center;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.16);
    font-size: 0.85rem;
    opacity: 0.85;
}

.developer-credit {
    text-align: center;
    margin-top: 4px;
    font-size: 0.8rem;
    opacity: 0.6;
}

/* Language Switch Button */
.language-link {
    position: fixed;
    top: 18px;
    right: 20px;
    z-index: 1000;
    background: var(--white);
    border-radius: 30px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 6px 14px;
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--primary-blue);
    font-weight: 500;
    font-size: 0.9rem;
    transition: var(--transition);
}

.language-link:hover {
    background: var(--primary-blue);
    color: var(--white);
}

.language-link i {
    margin-right: 8px;
}

body.rtl .language-link {
    right: auto;
    left: 20px;
}

body.rtl .language-link i {
    margin-right: 0;
    margin-left: 8px;
}

/* Lebanese Flag Badge */
.lebanese-flag {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 66px;
    height: 40px;
    background: linear-gradient(to bottom, #ed1c24 33%, #ffffff 33%, #ffffff 66%, #ed1c24 66%);
    border: 1px solid rgba(255,255,255,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    border-radius: 4px;
    z-index: 2;
}

.lebanese-flag span {
    font-size: 18px;
}

body.rtl .lebanese-flag {
    left: auto;
    right: 20px;
}

/* Responsive */
@media (max-width: 992px) {
    .about-content {
        flex-direction: column;
    }

    .contact-container {
        flex-direction: column;
    }

    .timeline::after {
        left: 24px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 58px;
        padding-right: 20px;
    }

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

    .timeline-item::after {
        left: 15px;
    }

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

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--white);
        flex-direction: column;
        padding: 14px 20px 18px;
        box-shadow: 0 8px 14px rgba(0, 0, 0, 0.12);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        margin: 8px 0;
    }

    .mobile-menu {
        display: block;
    }

    h1 {
        font-size: 2.2rem;
    }

    .section-title h2 {
        font-size: 1.7rem;
    }

    .footer-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero-content {
        flex-direction: column;
        text-align: center;
    }

    .hero-text {
        text-align: center;
    }

    .header-btns {
        justify-content: center;
    }

    .profile-img {
        width: 190px;
        height: 190px;
    }

    .btn {
        padding-inline: 22px;
    }
}

@media (max-width: 576px) {
    header.hero-header {
        min-height: 420px;
        padding: 26px 0 32px;
    }

    section {
        padding: 60px 0;
    }

    .personal-info {
        grid-template-columns: 1fr;
    }

    .language-link {
        top: 70px;
    }
}
/* ===== BETWEEN: RTL TIMELINE CENTER FIX ===== */
#education {
    direction: rtl;
}

#education .timeline {
    direction: ltr !important; /* Forces center like English */
    text-align: center;
    margin: 0 auto;
}

/* Put RTL back inside boxes ONLY */
#education .timeline-content {
    direction: rtl !important;
    text-align: right !important;
}

/* ===== FINAL HERO MOBILE FIX ===== */
@media (max-width: 768px) {
    header.hero-header {
        height: auto !important;
        padding: 40px 0 60px !important;
        background-position: center top !important;
    }

    .hero-content {
        flex-direction: column !important;
        text-align: center !important;
        gap: 20px !important;
    }

    .profile-img {
        width: 160px !important;
        height: 160px !important;
        margin: 0 auto !important;
    }

    .hero-text h1 {
        font-size: 26px !important;
        margin-top: 10px !important;
    }

    .tagline {
        max-width: 90% !important;
        margin: 0 auto 18px !important;
        font-size: 15px !important;
        line-height: 1.5 !important;
    }

    .header-btns {
        flex-direction: row !important;
        justify-content: center !important;
        gap: 12px !important;
    }

    .btn {
        padding: 10px 22px !important;
        font-size: 14px !important;
    }
}
