/* CSS Variables */
:root {
    --primary: #0066cc;
    --primary-dark: #004999;
    --primary-light: #e6f0ff;
    --secondary: #1a1a2e;
    --text: #333333;
    --text-light: #666666;
    --text-muted: #999999;
    --background: #ffffff;
    --background-alt: #f8f9fa;
    --border: #e5e7eb;
    --success: #10b981;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: all 0.3s ease;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
}

@media (min-width: 768px) {
    body {
        padding: 40px;
    }
}

/* Container */
.container {
    max-width: 800px;
    margin: 0 auto;
    background: var(--background);
    border-radius: 24px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--secondary) 0%, #16213e 100%);
    padding: 60px 40px;
    text-align: center;
    color: white;
}

.hero-content {
    max-width: 500px;
    margin: 0 auto;
}

.avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, #0052a3 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    box-shadow: 0 8px 32px rgba(0, 102, 204, 0.3);
}

.avatar-initials {
    font-size: 42px;
    font-weight: 700;
    color: white;
}

.avatar-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.hero h1 {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.02em;
}

.subtitle {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 20px;
}

.credentials {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.badge {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.813rem;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Social Links */
.social-links {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 24px;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.social-links a:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.social-links svg {
    width: 20px;
    height: 20px;
}

/* Sections */
.section {
    padding: 48px 40px;
    border-bottom: 1px solid var(--border);
}

.section:last-of-type {
    border-bottom: none;
}

.section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 24px;
    letter-spacing: -0.01em;
}

/* About Section */
.about p {
    color: var(--text-light);
    margin-bottom: 16px;
}

.about p:last-child {
    margin-bottom: 0;
}

/* Expertise Grid */
.expertise-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

@media (max-width: 600px) {
    .expertise-grid {
        grid-template-columns: 1fr;
    }
}

.expertise-item {
    background: var(--background-alt);
    padding: 24px;
    border-radius: var(--radius);
    transition: var(--transition);
}

.expertise-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.expertise-icon {
    width: 48px;
    height: 48px;
    background: var(--primary-light);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.expertise-icon svg {
    width: 24px;
    height: 24px;
    color: var(--primary);
}

.expertise-item h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 8px;
}

.expertise-item p {
    font-size: 0.875rem;
    color: var(--text-light);
}

/* Timeline */
.timeline-container {
    position: relative;
    padding-left: 32px;
}

.timeline-container::before {
    content: '';
    position: absolute;
    left: 6px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: var(--border);
}

.timeline-item {
    position: relative;
    padding-bottom: 28px;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: -26px;
    top: 6px;
    width: 14px;
    height: 14px;
    background: var(--primary);
    border-radius: 50%;
    border: 3px solid var(--background);
    box-shadow: 0 0 0 2px var(--primary);
}

.timeline-marker.current {
    background: var(--success);
    box-shadow: 0 0 0 2px var(--success);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 0 2px var(--success); }
    50% { box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.3); }
}

.timeline-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 4px;
}

.timeline-content p {
    font-size: 0.875rem;
    color: var(--text-light);
}

.timeline-date {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary);
    background: var(--primary-light);
    padding: 2px 10px;
    border-radius: 12px;
    margin-bottom: 8px;
}

/* Education */
.education-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.education-item {
    display: flex;
    gap: 16px;
    padding: 20px;
    background: var(--background-alt);
    border-radius: var(--radius);
    transition: var(--transition);
}

.education-item:hover {
    transform: translateX(4px);
}

.education-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.education-icon svg {
    width: 24px;
    height: 24px;
    color: white;
}

.education-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 4px;
}

.education-content p {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: 4px;
}

.education-content .year {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* Publications */
.publications-content {
    display: flex;
    align-items: flex-start;
    gap: 24px;
}

@media (max-width: 500px) {
    .publications-content {
        flex-direction: column;
        align-items: stretch;
    }
}

.stat-box {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 120px;
    height: 100px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: var(--radius);
    color: white;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1;
}

.stat-label {
    font-size: 0.75rem;
    text-align: center;
    margin-top: 4px;
    opacity: 0.9;
}

.publications-content p {
    color: var(--text-light);
}

/* Contact Form */
.contact {
    background: var(--background-alt);
}

.contact-intro {
    color: var(--text-light);
    margin-bottom: 32px;
}

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

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

.form-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--secondary);
}

.form-group input,
.form-group textarea {
    padding: 14px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: inherit;
    background: var(--background);
    transition: var(--transition);
}

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

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

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

.submit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 32px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 14px rgba(0, 102, 204, 0.4);
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 102, 204, 0.5);
}

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

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

/* Footer */
.footer {
    padding: 24px 40px;
    text-align: center;
    background: var(--background-alt);
    border-top: 1px solid var(--border);
}

.footer p {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Responsive Adjustments */
@media (max-width: 600px) {
    body {
        padding: 12px;
    }

    .container {
        border-radius: 16px;
    }

    .hero {
        padding: 40px 24px;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .section {
        padding: 32px 24px;
    }

    .section h2 {
        font-size: 1.25rem;
    }

    .avatar {
        width: 100px;
        height: 100px;
    }

    .avatar-initials {
        font-size: 36px;
    }
}

/* Success Message Styles */
.form-success {
    display: none;
    text-align: center;
    padding: 40px;
}

.form-success.show {
    display: block;
}

.form-success svg {
    width: 64px;
    height: 64px;
    color: var(--success);
    margin-bottom: 16px;
}

.form-success h3 {
    font-size: 1.25rem;
    color: var(--secondary);
    margin-bottom: 8px;
}

.form-success p {
    color: var(--text-light);
}

/* Loading State */
.submit-btn.loading {
    pointer-events: none;
    opacity: 0.7;
}

.submit-btn.loading span {
    display: none;
}

.submit-btn.loading::after {
    content: 'Sending...';
}
