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

:root {
    --primary-color: #1a5490;
    --secondary-color: #2980b9;
    --accent-color: #3498db;
    --success-color: #27ae60;
    --danger-color: #e74c3c;
    --light-bg: #f8f9fa;
    --border-color: #dee2e6;
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 5px 20px rgba(0, 0, 0, 0.15);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: #ffffff;
}

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

/* Navbar */
.navbar {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 1rem 0;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: white;
    cursor: pointer;
    text-decoration: none;
}

.logo:hover {
    color: rgba(255,255,255,0.85);
}

/* Back-to-top button */
#back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
    z-index: 999;
}

#back-to-top.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

#back-to-top:hover {
    background: var(--secondary-color);
}

/* Toast notification */
#toast {
    position: fixed;
    bottom: 5rem;
    right: 2rem;
    background: var(--text-dark);
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    font-size: 0.88rem;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
    z-index: 1000;
}

#toast.show {
    opacity: 1;
    transform: translateY(0);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: white;
    border-bottom: 2px solid white;
    padding-bottom: 0.3rem;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 5px 0;
    transition: 0.3s;
}

/* Main Content */
main {
    padding: 3rem 0;
    min-height: 70vh;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: var(--primary-color);
    border-bottom: 3px solid var(--accent-color);
    padding-bottom: 1rem;
}

h2 {
    font-size: 1.8rem;
    margin: 2rem 0 1.5rem;
    color: var(--primary-color);
}

h3 {
    font-size: 1.3rem;
    color: var(--secondary-color);
    margin: 1rem 0 0.5rem;
}

p {
    margin: 0.8rem 0;
    line-height: 1.8;
}

/* Profile Section */
.profile-section {
    background: var(--light-bg);
    padding: 2rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.profile-header {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
    margin-bottom: 2rem;
}

.profile-image {
    flex-shrink: 0;
}

.avatar-placeholder {
    width: 150px;
    height: 150px;
    background: linear-gradient(135deg, var(--secondary-color), var(--accent-color));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
    font-weight: bold;
    box-shadow: var(--shadow-lg);
}

.profile-photo {
    width: 150px;
    height: 150px;
    object-fit: cover;
    object-position: center top;
    border-radius: 10px;
    box-shadow: var(--shadow-lg);
    border: 3px solid var(--accent-color);
}

.profile-info {
    flex: 1;
}

.profile-info h1 {
    margin: 0;
    border: none;
    padding: 0;
    font-size: 2.2rem;
}

.title {
    font-size: 1.3rem;
    color: var(--secondary-color);
    font-weight: 600;
    margin: 0.5rem 0;
}

.institution {
    color: var(--text-light);
    margin: 1rem 0;
    line-height: 1.8;
}

.current-position {
    background: rgba(52, 152, 219, 0.1);
    padding: 0.8rem;
    border-left: 4px solid var(--accent-color);
    border-radius: 4px;
    margin: 1rem 0;
}

.profile-bio {
    margin: 2rem 0;
}

.profile-bio p {
    margin: 1rem 0;
    text-align: justify;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.btn-link {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    padding: 0.6rem 1.2rem;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.btn-link:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.contact-info {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    margin-top: 1.5rem;
    border-left: 4px solid var(--success-color);
}

.contact-info h3 {
    margin-top: 0;
}

.contact-info a {
    color: var(--accent-color);
    text-decoration: none;
}

.contact-info a:hover {
    text-decoration: underline;
}

/* Highlights Grid */
.highlights {
    margin: 3rem 0;
}

.highlight-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.highlight-card {
    background: linear-gradient(135deg, rgba(26, 84, 144, 0.05), rgba(52, 152, 219, 0.05));
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
}

.highlight-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-left-color: var(--accent-color);
}

.highlight-card h4 {
    color: var(--primary-color);
    margin-bottom: 0.8rem;
    font-size: 1.1rem;
}

.highlight-card p {
    font-size: 0.95rem;
    color: var(--text-light);
    margin: 0;
}

/* Education Section */
.education-section {
    margin: 2rem 0;
}

.education-item {
    background: var(--light-bg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--accent-color);
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

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

.education-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.education-header h3 {
    margin: 0;
}

.date {
    background: var(--primary-color);
    color: white;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

.institution {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 1rem;
}

.department {
    color: var(--text-light);
    margin: 0.5rem 0;
}

.grade {
    background: rgba(39, 174, 96, 0.1);
    padding: 0.5rem;
    border-radius: 4px;
    color: var(--success-color);
    font-weight: 600;
}

.advisor-info,
.thesis-info {
    background: white;
    padding: 1rem;
    border-radius: 5px;
    margin-top: 1rem;
}

.thesis-info h4 {
    margin-top: 0;
    color: var(--primary-color);
}

.thesis-info ul {
    list-style-position: inside;
    color: var(--text-light);
}

.thesis-info li {
    margin: 0.5rem 0;
}

/* News / Recent Updates Section */
.news-section {
    margin: 2.5rem 0;
}

.news-list {
    list-style: none;
    padding: 0;
    margin-top: 1rem;
}

.news-item {
    display: flex;
    gap: 1.2rem;
    align-items: flex-start;
    padding: 0.9rem 1rem;
    border-left: 3px solid var(--accent-color);
    margin-bottom: 0.8rem;
    background: var(--light-bg);
    border-radius: 0 6px 6px 0;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.news-item:hover {
    background: rgba(52, 152, 219, 0.07);
    border-left-color: var(--primary-color);
}

.news-date {
    min-width: 70px;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--primary-color);
    background: rgba(26, 84, 144, 0.08);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    text-align: center;
    height: fit-content;
    white-space: nowrap;
}

.news-text {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-dark);
}

.news-text a {
    color: var(--accent-color);
    text-decoration: none;
}

.news-text a:hover {
    text-decoration: underline;
}

/* Journey Section */
.journey-section {
    margin: 2.5rem 0;
}

.journey-section p {
    text-align: justify;
    line-height: 1.9;
    margin-bottom: 1.2rem;
    color: var(--text-dark);
}

.journey-section a {
    color: var(--accent-color);
    text-decoration: none;
}

.journey-section a:hover {
    text-decoration: underline;
}

/* Research Areas Diagram */
.diagram-section {
    background: var(--light-bg);
    border-radius: 10px;
    padding: 1.5rem 2rem 1rem;
    margin-bottom: 2.5rem;
    box-shadow: var(--shadow);
}

.diagram-intro {
    color: var(--text-light);
    margin: 0.5rem 0 1rem;
    font-size: 0.95rem;
}

.diagram-container {
    overflow-x: auto;
    margin: 0.5rem 0;
}

.diagram-legend {
    font-size: 0.82rem;
    color: var(--text-light);
    text-align: center;
    margin-top: 0.5rem;
}

/* Research Area Items */
.research-area-section {
    margin-top: 0;
}

.research-area-item {
    background: white;
    border-left: 4px solid var(--primary-color);
    padding: 1.5rem 1.8rem;
    margin-bottom: 1.8rem;
    border-radius: 0 8px 8px 0;
    box-shadow: var(--shadow);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.research-area-item:hover {
    box-shadow: var(--shadow-lg);
    transform: translateX(4px);
}

.research-area-item h2 {
    margin-top: 0;
    margin-bottom: 0.7rem;
    font-size: 1.35rem;
    color: var(--primary-color);
}

.research-area-item p {
    margin: 0;
    line-height: 1.8;
    text-align: justify;
}

/* Publications Section */
.publication-item {
    background: var(--light-bg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--secondary-color);
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.publication-item:hover {
    box-shadow: var(--shadow-lg);
}

.pub-header {
    margin-bottom: 1rem;
}

.pub-header h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    color: var(--primary-color);
}

.pub-date {
    background: var(--accent-color);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-block;
}

.publication-item p {
    margin: 0.5rem 0;
    font-size: 0.95rem;
}

.publication-item a {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 600;
}

.publication-item a:hover {
    text-decoration: underline;
}

/* Skills Section */
.skills-section {
    margin: 2rem 0;
}

.skill-category {
    margin: 2.5rem 0;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.skill-item {
    background: var(--light-bg);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.skill-item:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
}

.skill-item h3 {
    margin-top: 0;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.skill-bar {
    height: 8px;
    background: var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    margin: 0.8rem 0;
}

.skill-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 10px;
    transition: width 0.3s ease;
}

.skill-item p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin: 0.5rem 0 0 0;
}

.specialization-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.spec-item {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    border: 2px solid var(--border-color);
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.spec-item:hover {
    border-color: var(--accent-color);
    box-shadow: var(--shadow-lg);
}

.spec-item h3 {
    margin-top: 0;
    color: var(--secondary-color);
    font-size: 1rem;
}

.spec-item p {
    margin: 0.8rem 0;
    font-size: 0.9rem;
    color: var(--text-light);
}

/* Experience Section */
.experience-section,
.achievement-section {
    margin: 2rem 0;
}

.experience-item {
    background: var(--light-bg);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--success-color);
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

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

.exp-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.8rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.exp-header h3 {
    margin: 0;
}

.organization {
    color: var(--secondary-color);
    font-weight: 600;
    margin: 0.5rem 0;
}

.role {
    color: var(--text-light);
    font-size: 0.95rem;
    margin: 0.5rem 0;
}

/* Contact Section */
.contact-section {
    margin: 2rem 0;
}

.contact-card {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-lg);
}

.contact-card h2 {
    color: white;
    margin-top: 0;
    font-size: 2rem;
}

.contact-card p {
    margin: 1rem 0;
    font-size: 1.1rem;
}

.contact-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.contact-item {
    background: var(--light-bg);
    padding: 1.5rem;
    border-radius: 8px;
    border-top: 4px solid var(--accent-color);
    box-shadow: var(--shadow);
    text-align: center;
}

.contact-item h3 {
    margin-top: 0;
    color: var(--primary-color);
}

.contact-item p {
    margin: 0.5rem 0;
}

.label {
    color: var(--text-light);
    font-size: 0.9rem;
    font-style: italic;
}

/* Social Section */
.social-section {
    margin: 2rem 0;
}

.social-links-large {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.social-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    border-radius: 10px;
    text-decoration: none;
    color: white;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
    font-weight: 600;
    min-height: 140px;
}

.social-btn span {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.social-btn p {
    font-size: 0.85rem;
    margin: 0;
    opacity: 0.9;
}

.linkedin {
    background: linear-gradient(135deg, #0077B5, #0A66C2);
}

.scholar {
    background: linear-gradient(135deg, #4285F4, #34A853);
}

.orcid {
    background: linear-gradient(135deg, #A6CE39, #6DB33F);
}

.social-btn:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

/* Quick Links */
.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.quick-link {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    background: var(--light-bg);
    color: var(--primary-color);
    text-decoration: none;
    border-radius: 5px;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
    text-align: center;
    font-weight: 600;
}

.quick-link:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.quick-link.external::after {
    content: ' ↗';
}

/* Lists */
.achievements-list {
    list-style-position: inside;
    margin: 1.5rem 0;
}

.achievements-list li {
    margin: 1rem 0;
    line-height: 1.8;
    color: var(--text-dark);
}

/* Footer */
.footer {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-align: center;
    padding: 2rem;
    margin-top: 3rem;
    box-shadow: var(--shadow);
}

.footer p {
    margin: 0.5rem 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        width: 100%;
        background: var(--primary-color);
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
    }

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

    .nav-menu li {
        padding: 1rem 2rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav-menu a {
        display: block;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    .profile-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .avatar-placeholder {
        width: 120px;
        height: 120px;
    }

    .profile-info h1 {
        font-size: 1.8rem;
    }

    .education-header,
    .exp-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .skills-grid,
    .highlight-grid,
    .contact-details,
    .specialization-grid,
    .social-links-large {
        grid-template-columns: 1fr;
    }

    .social-links {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-link {
        text-align: center;
    }

    main {
        padding: 2rem 0;
    }
}

@media (max-width: 480px) {
    .navbar .container {
        flex-direction: column;
    }

    .logo {
        margin-bottom: 1rem;
    }

    h1 {
        font-size: 1.5rem;
    }

    h2 {
        font-size: 1.2rem;
    }

    .profile-section,
    .education-item,
    .publication-item,
    .skill-item,
    .contact-item {
        padding: 1rem;
    }

    .container {
        padding: 0 15px;
    }
}
