/* ====================================
   Root Variables - Color Palette
   ==================================== */
:root {
    --primary-color: #1a4d8f;
    --primary-dark: #0f3460;
    --primary-light: #2563a8;
    --secondary-color: #16537e;
    --accent-color: #e8505b;
    --text-dark: #2c3e50;
    --text-light: #6c757d;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --border-color: #dee2e6;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s ease;
}

/* ====================================
   Reset & Base Styles
   ==================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Cairo', 'Segoe UI', Tahoma, sans-serif;
    line-height: 1.7;
    color: var(--text-dark);
    background-color: var(--bg-white);
    direction: rtl;
    text-align: right;
}

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

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

ul {
    list-style: none;
}

/* ====================================
   Container & Layout
   ==================================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 40px;
    text-align: center;
    position: relative;
    padding-bottom: 20px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 50%;
    transform: translateX(50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 2px;
}

/* ====================================
   Navigation Bar
   ==================================== */
.navbar {
    background-color: var(--bg-white);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}

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

.nav-brand {
    margin-left: 40px;
}

.nav-brand h2 {
    color: var(--primary-color);
    font-size: 1.2rem;
    font-weight: 700;
    white-space: nowrap;
}

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

.nav-menu a {
    color: var(--text-dark);
    font-weight: 500;
    font-size: 1rem;
    padding: 8px 16px;
    border-radius: 6px;
    transition: var(--transition);
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary-color);
    background-color: var(--bg-light);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.nav-toggle span {
    width: 28px;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
    transition: var(--transition);
}

/* ====================================
   Hero Section
   ==================================== */
.hero {
    background: linear-gradient(135deg, var(--bg-light) 0%, #e3f2fd 100%);
    padding: 100px 0;
    min-height: 600px;
    display: flex;
    align-items: center;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-text h1 {
    font-size: 2.5rem;
    color: var(--primary-dark);
    margin-bottom: 15px;
    font-weight: 700;
}

.hero-text h2 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 10px;
    font-weight: 600;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 20px;
    font-weight: 500;
}

.hero-description {
    font-size: 1.1rem;
    color: var(--text-dark);
    line-height: 1.8;
    margin-bottom: 35px;
}

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

.btn {
    display: inline-block;
    padding: 14px 32px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    cursor: pointer;
    border: 2px solid transparent;
}

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

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

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

.btn-secondary:hover {
    background-color: var(--primary-color);
    color: var(--bg-white);
    transform: translateY(-2px);
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-image img {
    width: 100%;
    max-width: 450px;
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
    object-fit: cover;
}

/* ====================================
   About Section
   ==================================== */
.about {
    background-color: var(--bg-white);
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
    text-align: right;
}

.about-content p {
    font-size: 1.15rem;
    line-height: 1.9;
    color: var(--text-dark);
    margin-bottom: 20px;
}

/* ====================================
   Page Header
   ==================================== */
.page-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--bg-white);
    padding: 30px 0;
    text-align: center;
}

.page-header h1 {
    font-size: 2rem;
    margin-bottom: 8px;
    font-weight: 700;
}

.page-header p {
    font-size: 1.1rem;
    opacity: 0.95;
}

/* ====================================
   Timeline
   ==================================== */
.timeline {
    position: relative;
    padding: 20px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    right: 40px;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, var(--primary-color), var(--primary-light));
}

.timeline-item {
    position: relative;
    padding: 0 0 40px 0;
    margin-right: 60px;
}

.timeline-logo {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 180px;
    height: 180px;
    object-fit: contain;
    opacity: 0.50;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 0;
}

.timeline-content {
    position: relative;
    background-color: var(--bg-white);
    padding: 25px;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    overflow: hidden;
}

.timeline-content::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 250px;
    height: 250px;
    background: linear-gradient(135deg, rgba(0, 86, 179, 0.03) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}

.timeline-content:hover {
    box-shadow: var(--shadow-md);
    transform: translateX(-5px);
}

.timeline-content:hover .timeline-logo {
    opacity: 0.56;
}

.timeline-marker {
    position: absolute;
    right: -55px;
    top: 25px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: var(--primary-color);
    border: 4px solid var(--bg-white);
    box-shadow: var(--shadow-sm);
    z-index: 1;
}

.timeline-header {
    position: relative;
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    margin-bottom: 12px;
    z-index: 2;
}

.timeline-degree h3 {
    font-size: 1.4rem;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 5px;
}

.degree-major {
    font-size: 1.1rem;
    color: var(--text-dark);
    font-weight: 500;
    margin: 0;
}

.timeline-date {
    position: relative;
    display: inline-block;
    background-color: rgba(0, 86, 179, 0.12);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.9rem;
    color: #0056b3;
    font-weight: 500;
    margin-top: 8px;
    box-shadow: 0 1px 4px rgba(0, 86, 179, 0.1);
    border: 1px solid rgba(0, 86, 179, 0.15);
    z-index: 2;
}

.timeline-location {
    position: relative;
    color: var(--text-light);
    font-size: 1rem;
    margin-bottom: 12px;
    font-weight: 500;
    z-index: 2;
}

.timeline-description {
    position: relative;
    color: var(--text-dark);
    line-height: 1.7;
    margin-top: 12px;
    z-index: 2;
}

.timeline-list {
    position: relative;
    margin-top: 15px;
    padding-right: 20px;
    z-index: 2;
}

.timeline-list li {
    list-style: disc;
    color: var(--text-dark);
    line-height: 1.7;
    margin-bottom: 8px;
}

/* ====================================
   Education & Experience Sections
   ==================================== */
.education-section,
.experience-section {
    background-color: var(--bg-white);
}

.experience-section {
    background-color: var(--bg-light);
}

/* ====================================
   Modern Interactive Timeline
   ==================================== */
.modern-timeline {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 0;
}

/* Central timeline line */
.modern-timeline::before {
    content: '';
    position: absolute;
    right: 50%;
    transform: translateX(50%);
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, 
        var(--primary-color) 0%, 
        var(--primary-light) 50%, 
        var(--secondary-color) 100%);
    border-radius: 2px;
    box-shadow: 0 0 10px rgba(26, 77, 143, 0.3);
}

.timeline-block {
    position: relative;
    margin-bottom: 50px;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Alternating sides on desktop */
.timeline-block:nth-child(odd) {
    padding-left: calc(50% + 40px);
    text-align: right;
}

.timeline-block:nth-child(even) {
    padding-right: calc(50% + 40px);
    text-align: left;
}

/* Animated state */
.timeline-block.aos-animate {
    opacity: 1;
    transform: translateY(0);
}

/* Timeline dot */
.timeline-dot {
    position: absolute;
    right: 50%;
    transform: translateX(50%);
    top: 30px;
    width: 24px;
    height: 24px;
    background: var(--bg-white);
    border: 4px solid var(--primary-color);
    border-radius: 50%;
    z-index: 10;
    box-shadow: 0 0 0 4px rgba(26, 77, 143, 0.1),
                0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.timeline-block:hover .timeline-dot {
    transform: translateX(50%) scale(1.3);
    border-color: var(--accent-color);
    box-shadow: 0 0 0 8px rgba(232, 80, 91, 0.15),
                0 6px 20px rgba(232, 80, 91, 0.3);
}

/* Timeline connecting line to card */
.timeline-block:nth-child(odd)::before {
    content: '';
    position: absolute;
    left: 0;
    top: 36px;
    right: 50%;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        var(--primary-color) 100%);
    margin-right: 12px;
}

.timeline-block:nth-child(even)::before {
    content: '';
    position: absolute;
    right: 0;
    top: 36px;
    left: 50%;
    height: 2px;
    background: linear-gradient(270deg, 
        transparent 0%, 
        var(--primary-color) 100%);
    margin-left: 12px;
}

/* Timeline card */
.timeline-card {
    background: var(--bg-white);
    padding: 28px 32px;
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid transparent;
}

.timeline-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(26, 77, 143, 0.03) 0%, 
        transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.timeline-block:hover .timeline-card {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.timeline-block:hover .timeline-card::before {
    opacity: 1;
}

/* Date badge */
.timeline-date-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--bg-white);
    padding: 8px 20px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 16px;
    box-shadow: 0 4px 12px rgba(26, 77, 143, 0.25);
    transition: all 0.3s ease;
}

.timeline-block:hover .timeline-date-badge {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(26, 77, 143, 0.35);
}

.date-separator {
    opacity: 0.7;
    font-weight: 400;
}

/* Position title */
.timeline-position {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 12px;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.timeline-block:hover .timeline-position {
    color: var(--primary-color);
}

/* Institution */
.timeline-institution {
    font-size: 1.05rem;
    color: var(--text-light);
    margin: 0;
    font-weight: 500;
    line-height: 1.6;
}

/* ====================================
   Research Interests Section
   ==================================== */
.research-interests {
    background-color: var(--bg-white);
}

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

.interest-card {
    background-color: var(--bg-light);
    padding: 35px;
    border-radius: 12px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.interest-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.interest-card h3 {
    font-size: 1.4rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    font-weight: 600;
}

.interest-card p {
    color: var(--text-dark);
    line-height: 1.7;
}

/* ====================================
   Publications Section
   ==================================== */
.publications-section {
    background-color: var(--bg-light);
}

.publication-category {
    margin-bottom: 60px;
}

.publication-category:last-child {
    margin-bottom: 0;
}

.category-title {
    font-size: 1.8rem;
    color: var(--primary-dark);
    margin-bottom: 30px;
    font-weight: 600;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--primary-color);
}

.publication-item {
    display: flex;
    gap: 25px;
    background-color: var(--bg-white);
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.publication-item:hover {
    box-shadow: var(--shadow-md);
    transform: translateX(-5px);
}

.publication-year {
    background-color: var(--primary-color);
    color: var(--bg-white);
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1.1rem;
    height: fit-content;
    min-width: 70px;
    text-align: center;
}

.publication-content h4 {
    font-size: 1.2rem;
    color: var(--primary-dark);
    margin-bottom: 10px;
    font-weight: 600;
    line-height: 1.5;
}

.publication-authors {
    color: var(--text-dark);
    font-size: 1rem;
    margin-bottom: 8px;
}

.publication-journal {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 12px;
    line-height: 1.6;
}

.publication-links {
    display: flex;
    gap: 12px;
}

.pub-link {
    background-color: var(--primary-light);
    color: var(--bg-white);
    padding: 6px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
}

.pub-link:hover {
    background-color: var(--primary-dark);
}

/* ====================================
   PDF Viewer with Tabs
   ==================================== */
.pdf-tabs {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.pdf-tab {
    display: flex;
    align-items: center;
    gap: 10px;
    background-color: var(--bg-white);
    color: var(--text-dark);
    border: 2px solid var(--border-color);
    padding: 14px 28px;
    border-radius: 10px;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Cairo', sans-serif;
}

.pdf-tab:hover {
    border-color: var(--primary-color);
    background-color: var(--bg-light);
    transform: translateY(-2px);
}

.pdf-tab.active {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--bg-white);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.pdf-tab svg {
    flex-shrink: 0;
}

.pdf-viewer-container {
    position: relative;
    background-color: var(--bg-white);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.pdf-content {
    display: none;
    animation: fadeIn 0.4s ease-in-out;
}

.pdf-content.active {
    display: block;
}

.pdf-header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 25px 30px;
    background: linear-gradient(135deg, var(--bg-light) 0%, #e3f2fd 100%);
    border-bottom: 2px solid var(--border-color);
}

.pdf-header h3 {
    font-size: 1.4rem;
    color: var(--primary-dark);
    font-weight: 600;
    margin: 0;
    text-align: center;
}

.download-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: var(--primary-color);
    color: var(--bg-white);
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.download-btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.download-btn svg {
    flex-shrink: 0;
}

.pdf-iframe-wrapper {
    position: relative;
    width: 100%;
    height: 800px;
    background-color: var(--bg-light);
}

.pdf-iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.pdf-fallback {
    display: none;
    text-align: center;
    padding: 60px 20px;
    background-color: var(--bg-light);
}

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

.pdf-fallback .btn-primary {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--bg-white);
    padding: 12px 30px;
    border-radius: 8px;
    font-weight: 600;
    transition: var(--transition);
}

.pdf-fallback .btn-primary:hover {
    background-color: var(--primary-dark);
}

/* ====================================
   Blog Section
   ==================================== */
.blog-section {
    padding: 80px 0;
    background-color: var(--bg-light);
    min-height: 500px;
}

.blog-empty-state {
    text-align: center;
    padding: 80px 20px;
    max-width: 600px;
    margin: 0 auto;
}

.empty-state-icon {
    color: var(--primary-color);
    opacity: 0.6;
    margin-bottom: 30px;
    animation: fadeInUp 0.6s ease-out;
}

.empty-state-icon svg {
    display: inline-block;
}

.blog-empty-state h2 {
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 20px;
    font-weight: 700;
    animation: fadeInUp 0.6s ease-out 0.1s both;
}

.blog-empty-state p {
    font-size: 1.2rem;
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 15px;
    animation: fadeInUp 0.6s ease-out 0.2s both;
}

.empty-state-note {
    font-size: 1rem;
    color: var(--primary-color);
    font-weight: 600;
    margin-top: 25px;
}

/* Blog Posts Grid (for future use) */
.blog-posts {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.blog-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.blog-card-image {
    width: 100%;
    height: 220px;
    overflow: hidden;
}

.blog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.blog-card:hover .blog-card-image img {
    transform: scale(1.05);
}

.blog-card-content {
    padding: 25px;
}

.blog-date {
    display: inline-block;
    font-size: 0.9rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.blog-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--text-dark);
}

.blog-card p {
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 20px;
}

.blog-read-more {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: gap 0.3s ease;
    gap: 5px;
}

.blog-read-more:hover {
    gap: 10px;
}

.blog-read-more::after {
    content: '←';
    display: inline-block;
}

/* ====================================
   Contact Section
   ==================================== */
.contact-section {
    padding: 80px 0;
    background-color: var(--bg-light);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.contact-info {
    position: sticky;
    top: 100px;
}

.contact-image {
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    margin-bottom: 30px;
}

.contact-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.contact-image:hover img {
    transform: scale(1.02);
}

.contact-details {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.contact-details h3 {
    font-size: 1.8rem;
    color: var(--text-dark);
    margin-bottom: 25px;
    font-weight: 700;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 20px;
    color: var(--text-light);
}

.contact-item svg {
    color: var(--primary-color);
    flex-shrink: 0;
    margin-top: 2px;
}

.contact-item p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin: 0;
}

.cv-downloads {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 2px solid var(--border-color);
}

.cv-downloads h4 {
    font-size: 1.3rem;
    color: var(--text-dark);
    margin-bottom: 18px;
    font-weight: 700;
}

.cv-buttons {
    display: flex;
    flex-direction: row;
    gap: 12px;
    flex-wrap: wrap;
}

.cv-download-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    background: #e8f4f8;
    color: #5a7c8f;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    border: 1px solid #d0e5ed;
}

.cv-download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(90, 124, 143, 0.15);
    background: #deeef5;
    color: #4a6c7f;
}

.cv-download-btn:active {
    transform: translateY(-1px);
}

.cv-download-btn svg {
    flex-shrink: 0;
    animation: bounce 2s infinite;
}

.cv-download-btn:hover svg {
    animation: bounceHover 0.6s ease;
}

.cv-download-btn span {
    flex: 1;
}

.cv-english {
    background: #e8f4f8;
    border: 1px solid #d0e5ed;
}

.cv-english:hover {
    background: #deeef5;
    box-shadow: 0 6px 20px rgba(39, 174, 96, 0.4);
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-3px);
    }
}

@keyframes bounceHover {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

.contact-form-wrapper {
    background: white;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.contact-form-wrapper h3 {
    font-size: 2rem;
    color: var(--text-dark);
    margin-bottom: 10px;
    font-weight: 700;
}

.form-description {
    color: var(--text-light);
    font-size: 1.1rem;
    margin-bottom: 30px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
}

.form-group input,
.form-group textarea {
    padding: 14px 18px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    font-family: 'Cairo', sans-serif;
    transition: all 0.3s ease;
    background-color: #f9f9f9;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background-color: white;
    box-shadow: 0 0 0 3px rgba(41, 128, 185, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

.submit-btn {
    background: var(--primary-color);
    color: white;
    padding: 16px 32px;
    border: none;
    border-radius: 8px;
    font-size: 1.2rem;
    font-weight: 600;
    font-family: 'Cairo', sans-serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.submit-btn:hover {
    background: #2c5d7a;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(41, 128, 185, 0.3);
}

.submit-btn:active {
    transform: translateY(0);
}

.submit-btn svg {
    transition: transform 0.3s ease;
}

.submit-btn:hover svg {
    transform: translateX(-3px);
}

.form-message {
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    display: none;
    animation: slideDown 0.3s ease;
}

.form-message.success {
    display: block;
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-message.error {
    display: block;
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ====================================
   Footer
   ==================================== */
.footer {
    background-color: var(--primary-dark);
    color: var(--bg-white);
    padding: 15px 0;
}

.footer-bottom {
    text-align: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    margin: 0;
}

/* ====================================
   Responsive Design - Tablet
   ==================================== */
@media (max-width: 992px) {
    .section-title {
        font-size: 2rem;
    }

    .hero {
        padding: 60px 0;
        min-height: auto;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .hero-text h1 {
        font-size: 2rem;
    }

    .hero-text h2 {
        font-size: 1.6rem;
    }

    .hero-image {
        order: -1;
    }

    .page-header h1 {
        font-size: 2.5rem;
    }

    .timeline::before {
        right: 20px;
    }

    .timeline-item {
        margin-right: 40px;
    }

    .timeline-logo {
        width: 120px;
        height: 120px;
    }

    .timeline-marker {
        right: -35px;
    }

    .publication-item {
        flex-direction: column;
        gap: 15px;
    }

    .publication-year {
        width: fit-content;
    }

    /* PDF Viewer - Tablet */
    .pdf-tabs {
        gap: 10px;
    }

    .pdf-tab {
        padding: 12px 22px;
        font-size: 1rem;
    }

    .pdf-header {
        padding: 20px 25px;
    }

    .pdf-header h3 {
        font-size: 1.2rem;
    }

    .pdf-iframe-wrapper {
        height: 700px;
    }

    /* Modern Timeline - Tablet: Switch to single-side */
    .modern-timeline::before {
        right: 30px;
        transform: none;
    }

    .timeline-block:nth-child(odd),
    .timeline-block:nth-child(even) {
        padding-left: 70px;
        padding-right: 0;
        text-align: right;
    }

    .timeline-dot {
        right: 18px;
        transform: none;
    }

    .timeline-block:hover .timeline-dot {
        transform: scale(1.3);
    }

    .timeline-block:nth-child(odd)::before,
    .timeline-block:nth-child(even)::before {
        right: 30px;
        left: auto;
        width: 28px;
        top: 36px;
        background: linear-gradient(90deg, 
            transparent 0%, 
            var(--primary-color) 100%);
        margin: 0;
    }
}

/* ====================================
   Responsive Design - Mobile
   ==================================== */
@media (max-width: 768px) {
    section {
        padding: 50px 0;
    }

    .container {
        padding: 0 15px;
    }

    .nav-menu {
        position: fixed;
        top: 70px;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: calc(100vh - 70px);
        background-color: var(--bg-white);
        flex-direction: column;
        align-items: flex-start;
        padding: 30px 20px;
        box-shadow: var(--shadow-lg);
        transition: var(--transition);
        gap: 0;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu li {
        width: 100%;
        border-bottom: 1px solid var(--border-color);
    }

    .nav-menu a {
        display: block;
        width: 100%;
        padding: 15px 10px;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translateY(10px);
    }

    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translateY(-10px);
    }

    .section-title {
        font-size: 1.8rem;
    }

    .hero {
        padding: 40px 0;
    }

    .hero-text h1 {
        font-size: 1.7rem;
    }

    .hero-text h2 {
        font-size: 1.4rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .page-header {
        padding: 30px 0;
    }

    .page-header h1 {
        font-size: 2rem;
    }

    .page-header p {
        font-size: 1.1rem;
    }

    .interests-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .timeline-header {
        flex-direction: column;
        align-items: flex-start;
    }

    /* PDF Viewer - Mobile */
    .pdf-tabs {
        flex-direction: column;
        gap: 12px;
    }

    .pdf-tab {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
        font-size: 1rem;
    }

    .pdf-header {
        padding: 20px;
    }

    .pdf-header h3 {
        font-size: 1.1rem;
    }

    .pdf-iframe-wrapper {
        height: 600px;
    }

    .blog-empty-state h2 {
        font-size: 2rem;
    }

    .blog-empty-state p {
        font-size: 1.1rem;
    }
    
    .blog-posts {
        grid-template-columns: 1fr;
    }
    
    .empty-state-icon svg {
        width: 80px;
        height: 80px;
    }

    /* Contact Page - Mobile */
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .contact-info {
        position: static;
    }

    .contact-form-wrapper {
        padding: 25px;
    }

    .contact-form-wrapper h3 {
        font-size: 1.6rem;
    }

    .contact-details {
        padding: 20px;
    }

    .contact-details h3 {
        font-size: 1.5rem;
    }

    .contact-item {
        font-size: 1rem;
    }

    .cv-downloads h4 {
        font-size: 1.1rem;
    }

    .cv-buttons {
        flex-direction: row;
        gap: 8px;
    }

    .cv-download-btn {
        flex: 1;
        min-width: 0;
        padding: 12px 12px;
        font-size: 0.85rem;
        gap: 8px;
    }

    .cv-download-btn span {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .cv-download-btn svg {
        width: 18px;
        height: 18px;
    }

    .form-group input,
    .form-group textarea {
        padding: 12px 16px;
    }

    .submit-btn {
        padding: 14px 28px;
        font-size: 1.1rem;
    }

    /* Modern Timeline - Mobile */
    .modern-timeline {
        padding: 20px 0;
    }

    .modern-timeline::before {
        right: 20px;
    }

    .timeline-block {
        margin-bottom: 40px;
        padding-left: 55px;
    }

    .timeline-dot {
        right: 12px;
        width: 20px;
        height: 20px;
        border-width: 3px;
    }

    .timeline-block:nth-child(odd)::before,
    .timeline-block:nth-child(even)::before {
        right: 20px;
        width: 22px;
    }

    .timeline-card {
        padding: 20px 24px;
    }

    .timeline-date-badge {
        font-size: 0.85rem;
        padding: 6px 16px;
        gap: 6px;
    }

    .timeline-position {
        font-size: 1.2rem;
    }

    .timeline-institution {
        font-size: 0.95rem;
    }
}

/* ====================================
   Small Mobile Devices
   ==================================== */
@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    .nav-brand h2 {
        font-size: 1rem;
    }

    .hero-text h1 {
        font-size: 1.5rem;
    }

    .hero-text h2 {
        font-size: 1.2rem;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .page-header h1 {
        font-size: 1.7rem;
    }

    .timeline-item {
        margin-right: 30px;
    }

    .timeline-logo {
        width: 100px;
        height: 100px;
    }

    .timeline-content::before {
        width: 150px;
        height: 150px;
    }

    .timeline-marker {
        right: -30px;
        width: 15px;
        height: 15px;
        top: 20px;
    }

    .timeline::before {
        right: 15px;
        width: 2px;
    }

    .publication-links {
        flex-wrap: wrap;
    }

    /* CV Buttons - Small Mobile */
    .cv-buttons {
        gap: 6px;
    }

    .cv-download-btn {
        padding: 10px 8px;
        font-size: 0.8rem;
        gap: 6px;
    }

    .cv-download-btn svg {
        width: 16px;
        height: 16px;
    }

    /* PDF Viewer - Small Mobile */
    .pdf-tab {
        padding: 12px 16px;
        font-size: 0.9rem;
        gap: 8px;
    }

    .pdf-tab svg {
        width: 16px;
        height: 16px;
    }

    .pdf-header h3 {
        font-size: 1rem;
    }

    .pdf-iframe-wrapper {
        height: 500px;
    }

    /* Modern Timeline - Small Mobile */
    .modern-timeline {
        padding: 15px 0;
    }

    .modern-timeline::before {
        right: 15px;
        width: 3px;
    }

    .timeline-block {
        margin-bottom: 35px;
        padding-left: 45px;
    }

    .timeline-dot {
        right: 9px;
        width: 16px;
        height: 16px;
        border-width: 3px;
    }

    .timeline-block:nth-child(odd)::before,
    .timeline-block:nth-child(even)::before {
        right: 15px;
        width: 18px;
    }

    .timeline-card {
        padding: 18px 20px;
    }

    .timeline-date-badge {
        font-size: 0.8rem;
        padding: 5px 14px;
    }

    .timeline-position {
        font-size: 1.1rem;
    }

    .timeline-institution {
        font-size: 0.9rem;
    }
}

/* ====================================
   Videos Section - Horizontal Carousel
   ==================================== */
.videos-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e8eef5 100%);
    padding: 80px 0 100px;
    overflow: hidden;
}

.container-full {
    width: 100%;
    max-width: 100%;
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    font-size: 1.1rem;
    margin-top: -30px;
    margin-bottom: 40px;
}

.videos-carousel-wrapper {
    position: relative;
    margin-top: 60px;
    padding: 60px 80px;
    overflow: hidden;
}

.videos-carousel {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    min-height: 500px;
    perspective: 2000px;
    perspective-origin: center center;
}

.videos-carousel::-webkit-scrollbar {
    display: none;
}

.video-card {
    position: absolute;
    width: 450px;
    background-color: var(--bg-white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    transform-style: preserve-3d;
    backface-visibility: hidden;
    will-change: transform, opacity;
}

.video-card.featured {
    width: 520px;
}

.video-card.center {
    z-index: 10;
    opacity: 1;
    transform: translateX(0) translateZ(0) scale(1) rotateY(0deg);
    box-shadow: 0 20px 60px rgba(26, 77, 143, 0.3);
    filter: brightness(1);
}

.video-card.center:hover {
    transform: translateX(0) translateZ(0) scale(1.03) rotateY(0deg);
    box-shadow: 0 25px 70px rgba(26, 77, 143, 0.4);
}

.video-card.center .play-button {
    opacity: 1;
    pointer-events: auto;
}

.video-card:not(.center) .play-button {
    opacity: 0.6;
}

.video-card.left-1,
.video-card.right-1 {
    z-index: 8;
    opacity: 0.7;
    transform: scale(0.85);
    filter: brightness(0.9);
}

.video-card.left-2,
.video-card.right-2 {
    z-index: 6;
    opacity: 0.5;
    transform: scale(0.7);
    filter: brightness(0.8);
}

.video-card.left-3,
.video-card.right-3,
.video-card.hidden {
    z-index: 4;
    opacity: 0.2;
    transform: scale(0.6);
    filter: brightness(0.7);
    pointer-events: none;
}

.video-card.left-1 {
    transform: translateX(-420px) scale(0.85) rotateY(25deg);
}

.video-card.left-2 {
    transform: translateX(-720px) scale(0.7) rotateY(35deg);
}

.video-card.left-3 {
    transform: translateX(-950px) scale(0.6) rotateY(40deg);
}

.video-card.right-1 {
    transform: translateX(420px) scale(0.85) rotateY(-25deg);
}

.video-card.right-2 {
    transform: translateX(720px) scale(0.7) rotateY(-35deg);
}

.video-card.right-3 {
    transform: translateX(950px) scale(0.6) rotateY(-40deg);
}

.video-card:not(.center):hover {
    opacity: 0.85;
    filter: brightness(0.95);
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .video-card {
        transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .carousel-nav:hover {
        background: rgba(255, 255, 255, 0.98);
        color: var(--primary-color);
        transform: translateY(-50%);
    }
    
    .carousel-nav:active {
        background: var(--primary-color);
        color: var(--bg-white);
        transform: translateY(-50%) scale(0.9);
    }
}

.video-thumbnail {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 */
    overflow: hidden;
    background: linear-gradient(135deg, #1a4d8f 0%, #0f3460 100%);
}

.video-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.4s ease;
}

.video-card:hover .video-thumbnail img {
    transform: scale(1.15);
    filter: brightness(1.1);
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.7) 0%,
        rgba(0, 0, 0, 0.3) 40%,
        transparent 100%
    );
    opacity: 0;
    transition: opacity 0.4s ease;
}

.video-card:hover .video-overlay {
    opacity: 1;
}

.video-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, #e8505b, #d4424d);
    color: var(--bg-white);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(232, 80, 91, 0.4);
    z-index: 3;
}

.video-duration {
    position: absolute;
    bottom: 15px;
    left: 15px;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    color: var(--bg-white);
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    z-index: 3;
}

.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 2;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.video-card.featured .play-button {
    width: 90px;
    height: 90px;
}

.video-card:hover .play-button {
    background: var(--primary-color);
    color: var(--bg-white);
    transform: translate(-50%, -50%) scale(1.15);
    box-shadow: 0 8px 30px rgba(26, 77, 143, 0.4);
}

.video-info {
    padding: 22px;
}

.video-category {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(26, 77, 143, 0.08);
    color: var(--primary-color);
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.video-category svg {
    flex-shrink: 0;
}

.video-info h3 {
    font-size: 1.15rem;
    color: var(--primary-dark);
    margin-bottom: 10px;
    font-weight: 700;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-card.featured .video-info h3 {
    font-size: 1.3rem;
}

.video-info p {
    font-size: 0.95rem;
    color: var(--text-light);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Carousel Navigation Buttons */
.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.98);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 20;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    color: var(--primary-color);
}

.carousel-nav:hover {
    background: var(--primary-color);
    color: var(--bg-white);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 30px rgba(26, 77, 143, 0.3);
}

.carousel-nav:active {
    transform: translateY(-50%) scale(0.95);
}

.carousel-nav-right {
    right: 20px;
}

.carousel-nav-left {
    left: 20px;
}

/* Carousel Indicators */
.carousel-indicators {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 40px;
    padding: 0 20px;
}

.carousel-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(26, 77, 143, 0.2);
    border: none;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0;
    position: relative;
}

.carousel-indicator::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: inherit;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.carousel-indicator:hover::after {
    opacity: 0.1;
    background: var(--primary-color);
}

.carousel-indicator.active {
    background: var(--primary-color);
    width: 30px;
    border-radius: 6px;
}

.carousel-indicator:hover {
    background: var(--primary-light);
    transform: scale(1.1);
}

/* Video Modal */
.video-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    padding: 20px;
    animation: fadeIn 0.3s ease-out;
}

.video-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-modal-content {
    position: relative;
    width: 100%;
    max-width: 1200px;
    background-color: #000;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.video-modal-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: var(--bg-white);
    cursor: pointer;
    padding: 10px;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10001;
}

.video-modal-close:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: rotate(90deg) scale(1.1);
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    overflow: hidden;
}

.video-wrapper iframe,
.video-wrapper video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ====================================
   Gallery Section
   ==================================== */
.gallery-section {
    background-color: var(--bg-white);
    padding: 80px 0;
}

.gallery-tabs {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.gallery-tab {
    display: flex;
    align-items: center;
    gap: 10px;
    background-color: var(--bg-white);
    color: var(--text-dark);
    border: 2px solid var(--border-color);
    padding: 14px 28px;
    border-radius: 10px;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Cairo', sans-serif;
}

.gallery-tab:hover {
    border-color: var(--primary-color);
    background-color: var(--bg-light);
    transform: translateY(-2px);
}

.gallery-tab.active {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--bg-white);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.gallery-tab svg {
    flex-shrink: 0;
}

.gallery-content {
    display: none;
    animation: fadeIn 0.4s ease-in-out;
}

.gallery-content.active {
    display: block;
}

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

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    cursor: pointer;
    aspect-ratio: 1 / 1;
    background-color: var(--bg-light);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(26, 77, 143, 0.85), rgba(232, 80, 91, 0.85));
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
    color: var(--bg-white);
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    padding: 20px;
    animation: fadeIn 0.3s ease-out;
}

.lightbox.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    left: 20px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: none;
    color: var(--bg-white);
    cursor: pointer;
    padding: 12px;
    border-radius: 50%;
    transition: var(--transition);
    z-index: 10001;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: none;
    color: var(--bg-white);
    cursor: pointer;
    padding: 12px;
    border-radius: 50%;
    transition: var(--transition);
    z-index: 10001;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
    right: 20px;
}

.lightbox-next {
    left: 20px;
}

/* ====================================
   Responsive - Videos & Gallery - Tablet
   ==================================== */
@media (max-width: 992px) {
    .videos-carousel-wrapper {
        padding: 50px 60px;
    }
    
    .videos-carousel {
        min-height: 450px;
        perspective: 1800px;
    }
    
    .video-card {
        width: 380px;
    }
    
    .video-card.featured {
        width: 450px;
    }

    .video-card.left-1 {
        transform: translateX(-360px) scale(0.85) rotateY(25deg);
    }
    
    .video-card.left-2 {
        transform: translateX(-620px) scale(0.7) rotateY(35deg);
    }
    
    .video-card.right-1 {
        transform: translateX(360px) scale(0.85) rotateY(-25deg);
    }
    
    .video-card.right-2 {
        transform: translateX(620px) scale(0.7) rotateY(-35deg);
    }
    
    .carousel-nav {
        width: 45px;
        height: 45px;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 16px;
    }
    
    .gallery-tabs {
        gap: 12px;
    }
    
    .gallery-tab {
        padding: 12px 22px;
        font-size: 1rem;
    }
}

/* ====================================
   Responsive - Videos & Gallery - Mobile
   ==================================== */
@media (max-width: 768px) {
    .videos-section,
    .gallery-section {
        padding: 50px 0 70px;
    }
    
    .videos-carousel-wrapper {
        padding: 40px 20px;
    }
    
    .videos-carousel {
        min-height: 400px;
        perspective: 1500px;
    }
    
    .video-card {
        width: 320px;
    }
    
    .video-card.featured {
        width: 360px;
    }

    .video-card.left-1 {
        transform: translateX(-300px) scale(0.8) rotateY(20deg);
    }
    
    .video-card.left-2 {
        transform: translateX(-520px) scale(0.65) rotateY(30deg);
    }
    
    .video-card.right-1 {
        transform: translateX(300px) scale(0.8) rotateY(-20deg);
    }
    
    .video-card.right-2 {
        transform: translateX(520px) scale(0.65) rotateY(-30deg);
    }
    
    .video-info h3 {
        font-size: 1.05rem;
    }
    
    .video-card.featured .video-info h3 {
        font-size: 1.15rem;
    }
    
    .video-info p {
        font-size: 0.9rem;
    }
    
    .play-button {
        width: 65px;
        height: 65px;
    }
    
    .video-card.featured .play-button {
        width: 75px;
        height: 75px;
    }
    
    .carousel-nav {
        width: 40px;
        height: 40px;
    }
    
    .carousel-nav-right {
        right: 5px;
    }
    
    .carousel-nav-left {
        left: 5px;
    }
    
    .carousel-indicators {
        margin-top: 20px;
    }

    /* Mobile landscape optimization */
    @media (max-height: 600px) and (orientation: landscape) {
        .videos-carousel {
            min-height: 320px;
        }
        
        .video-card {
            width: 260px;
        }
        
        .video-card.featured {
            width: 280px;
        }
        
        .videos-section {
            padding: 30px 0 40px;
        }
        
        .videos-carousel-wrapper {
            padding: 20px 20px;
        }
    }
    
    .section-subtitle {
        font-size: 0.95rem;
        margin-top: -25px;
        margin-bottom: 30px;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 12px;
    }
    
    .gallery-tabs {
        flex-direction: column;
        gap: 12px;
    }
    
    .gallery-tab {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
    }
    
    .video-modal-close {
        top: -45px;
        width: 42px;
        height: 42px;
    }
    
    .lightbox-close {
        top: 10px;
        left: 10px;
        width: 45px;
        height: 45px;
    }
    
    .lightbox-nav {
        width: 45px;
        height: 45px;
    }
    
    .lightbox-prev {
        right: 10px;
    }
    
    .lightbox-next {
        left: 10px;
    }
}

/* ====================================
   Responsive - Videos & Gallery - Small Mobile
   ==================================== */
@media (max-width: 480px) {
    .videos-section {
        padding: 40px 0 60px;
    }
    
    .videos-carousel-wrapper {
        padding: 30px 10px;
    }

    .videos-carousel {
        min-height: 350px;
        perspective: 1200px;
    }
    
    .video-card {
        width: 280px;
    }
    
    .video-card.featured {
        width: 300px;
    }

    .video-card.left-1 {
        transform: translateX(-250px) scale(0.75) rotateY(15deg);
    }
    
    .video-card.left-2,
    .video-card.left-3 {
        transform: translateX(-450px) scale(0.6) rotateY(25deg);
    }
    
    .video-card.right-1 {
        transform: translateX(250px) scale(0.75) rotateY(-15deg);
    }
    
    .video-card.right-2,
    .video-card.right-3 {
        transform: translateX(450px) scale(0.6) rotateY(-25deg);
    }

    .video-card.left-2,
    .video-card.right-2,
    .video-card.left-3,
    .video-card.right-3 {
        opacity: 0.3;
    }
    
    .video-info {
        padding: 18px;
    }
    
    .video-info h3 {
        font-size: 1rem;
    }
    
    .video-card.featured .video-info h3 {
        font-size: 1.1rem;
    }
    
    .video-info p {
        font-size: 0.85rem;
    }
    
    .play-button {
        width: 55px;
        height: 55px;
    }
    
    .play-button svg {
        width: 45px;
        height: 45px;
    }
    
    .video-card.featured .play-button {
        width: 65px;
        height: 65px;
    }
    
    .carousel-nav {
        width: 36px;
        height: 36px;
    }
    
    .carousel-nav svg {
        width: 20px;
        height: 20px;
    }
    
    .carousel-indicator {
        width: 10px;
        height: 10px;
    }
    
    .carousel-indicator.active {
        width: 24px;
    }
    
    .section-subtitle {
        font-size: 0.9rem;
        margin-top: -20px;
        margin-bottom: 25px;
        padding: 0 10px;
    }
    
    .video-badge {
        font-size: 0.75rem;
        padding: 5px 10px;
        top: 10px;
        right: 10px;
    }
    
    .video-duration {
        font-size: 0.75rem;
        padding: 4px 10px;
        bottom: 10px;
        left: 10px;
    }
    
    .video-category {
        font-size: 0.8rem;
        padding: 4px 10px;
    }
    
    .video-category svg {
        width: 14px;
        height: 14px;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 10px;
    }
    
    .gallery-tab {
        padding: 12px 16px;
        font-size: 0.95rem;
    }
    
    .lightbox-close,
    .lightbox-nav {
        width: 40px;
        height: 40px;
    }
    
    .lightbox-close svg,
    .lightbox-nav svg {
        width: 24px;
        height: 24px;
    }
    
    .video-modal-close {
        width: 38px;
        height: 38px;
        top: -42px;
    }
    
    .video-modal-close svg {
        width: 24px;
        height: 24px;
    }
}

/* ====================================
   Smooth Animations
   ==================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content,
.about-content,
.timeline-item,
.highlight-card,
.publication-item {
    animation: fadeIn 0.6s ease-out;
}

/* ====================================
   Print Styles
   ==================================== */
@media print {
    .navbar,
    .nav-toggle,
    .hero-buttons,
    .footer {
        display: none;
    }

    body {
        color: black;
        background: white;
    }

    .page-header {
        background: none;
        color: black;
        border-bottom: 2px solid black;
    }
}

