/* =====================================================
   GLOBAL SETTINGS & ANIMATIONS
===================================================== */
html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Segoe UI", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* Fade Up (used across site) */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Fade In Left (home header only) */
@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* =====================================================
   HEADER
===================================================== */
header {
    background: linear-gradient(to right, #ffffff 30%, #1d6fa5 100%);
    padding: 5px;
    overflow: hidden;
}

.header-container {
    max-width: 1300px;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

/* Logos & text (default = no animation) */
.header-logo img,
.header-text,
.header-iit-logo img {
    opacity: 1;
    animation: none;
}

/* home page header animation */
.home .header-logo img {
    opacity: 0;
    animation: fadeInLeft 1.2s ease-out forwards;
}

.home .header-text {
    opacity: 0;
    animation: fadeInLeft 1.2s ease-out forwards;
    animation-delay: 0.15s;
}

.home .header-iit-logo img {
    opacity: 0;
    animation: fadeInLeft 1.2s ease-out forwards;
    animation-delay: 0.3s;
}

/* Logo sizing */
.header-logo img {
    max-width: 300px;
    width: 100%;
    height: auto;
}

.header-iit-logo img {
    max-width: 170px;
    width: 100%;
    height: auto;
}

/* Header Typography */
.lab-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.5rem;
    font-weight: 500;
    letter-spacing: 3px;
    color: #0b3c5d;
    text-transform: uppercase;
}

.lab-subtitle {
    font-family: "Times New Roman", Georgia, serif;
    font-size: 1rem;
    font-weight: 500;
    color: #333;
    line-height: 1.5;
}

/* =====================================================
   NAVIGATION
===================================================== */
nav {
    background: #ffffff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

/* Hamburger button — hidden on desktop */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px 16px;
    flex-direction: column;
    gap: 5px;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: #0b3c5d;
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* Hamburger → X animation */
.nav-toggle.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.nav-toggle.open span:nth-child(2) {
    opacity: 0;
}
.nav-toggle.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

nav ul {
    display: flex;
    justify-content: center;
    align-items: center;
    list-style: none;
    padding: 8px;
    margin: 0;
    gap: 60px;
    flex-wrap: nowrap;
}

nav ul li {
    margin: 0;
}

nav ul li a {
    text-decoration: none;
    color: #0b3c5d;
    font-weight: 600;
    white-space: nowrap;
}

nav ul li a:hover {
    color: #1d6fa5;
}

/* =====================================================
   SECTIONS & CARDS (Fade-up on load)
===================================================== */
section {
    padding: 0 20px;
    max-width: 1100px;
    margin: auto;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 1s ease-out forwards;
    animation-delay: 0.2s;
}

section h2 {
    color: #0b3c5d;
    margin-bottom: 20px;
    border-left: 5px solid #1d6fa5;
    padding-left: 15px;
}

.card {
    background: white;
    padding: 25px;
    margin-bottom: 25px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 1s ease-out forwards;
    animation-delay: 0.3s;
}

/* =====================================================
   LAB VISION LAYOUT
===================================================== */
.lab-vision-container {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    padding: 20px 0;
    opacity: 0;
    transform: translateY(40px);
    animation: fadeUp 1.2s ease-out forwards;
    animation-delay: 0.2s;
}

.lab-vision-text {
    flex: 1;
}

.lab-vision-image img {
    max-width: 390px;
    width: 100%;
    height: auto;
    flex-shrink: 0;
}

/* =====================================================
   PI PROFILE
===================================================== */
.pi-profile {
    display: flex;
    gap: 50px;
    align-items: center;
    flex-wrap: wrap;
}

.pi-profile img {
    width: 360px;
    height: auto;
}

.pi-details h3 {
    margin-top: 0;
    color: #0b3c5d;
}

.pi-details p {
    margin: 6px 0;
}

.pi-details ul {
    margin: 8px 0 15px 20px;
}

/* =====================================================
   PhD PROFILE
===================================================== */
.phd-profile {
    display: flex;
    gap: 40px;
    align-items: center;
    flex-wrap: wrap;
}

.phd-profile img {
    width: 200px;
    height: auto;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.phd-details h3 {
    margin-top: 0;
    color: #0b3c5d;
}

.phd-details p {
    margin: 6px 0;
    line-height: 1.5;
}

.phd-details ul {
    margin: 8px 0 15px 20px;
}

/* =====================================================
   CONTACT
===================================================== */
.contact-card {
    display: flex;
    gap: 30px;
    align-items: stretch;
}

.contact-text {
    flex: 1.2;
}

.contact-map {
    flex: 1;
    min-height: 260px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* =====================================================
   NEWS
===================================================== */
.news-list {
    list-style-type: decimal;
    padding-left: 32px;
}

.news-list > li {
    list-style-position: outside;
}

.news-card {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    margin-bottom: 25px;
}

.news-text {
    flex: 2;
}

.news-image img {
    max-width: 220px;
    border-radius: 8px;
}

/* =====================================================
   FOOTER
===================================================== */
footer {
    background: #0b3c5d;
    color: white;
    text-align: center;
    padding: 25px 15px;
    margin-top: 40px;
}

/* =====================================================
   RESPONSIVE — TABLET (≤ 900px)
===================================================== */
@media (max-width: 900px) {
    .header-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 14px 16px;
        gap: 10px;
    }

    .header-logo img {
        max-width: 200px;
    }

    .header-iit-logo img {
        max-width: 150px;
    }

    .lab-title {
        font-size: 1.1rem;
        letter-spacing: 2px;
    }

    .lab-subtitle {
        font-size: 0.88rem;
    }


    /* Switch to hamburger nav */
    .nav-toggle {
        display: flex;
        margin-left: auto;
    }

    nav {
        display: flex;
        flex-direction: column;
    }

    nav ul {
        display: none;
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        padding: 0;
        width: 100%;
    }

    nav ul.open {
        display: flex;
    }

    nav ul li {
        width: 100%;
        border-top: 1px solid #e8edf2;
    }

    nav ul li a {
        display: block;
        padding: 12px 20px;
        font-size: 0.95rem;
    }

    nav ul li a:hover {
        background: #f0f6fc;
    }
}

/* =====================================================
   RESPONSIVE — MOBILE (≤ 768px)
===================================================== */
   @media (max-width: 768px) {
   header {
    padding: 14px 16px;
    background: linear-gradient(to bottom, #ffffff 30%, #1d6fa5 100%);
}

    .header-logo,
    .header-iit-logo {
        display: flex;
        justify-content: center;
    }

    .header-text {
        padding: 0;
    }

   section {
        padding: 0 14px;
    }

    .card {
        padding: 18px;
    }

    /* Lab vision */
    .lab-vision-container {
        flex-direction: column;
        text-align: center;
    }

    .lab-vision-image img {
        max-width: 100%;
    }

    /* PI profile */
    .pi-profile {
        flex-direction: column;
        text-align: center;
    }

    .pi-profile img {
        width: 100%;
        max-width: 300px;
    }

    /* PhD profile */
    .phd-profile {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .phd-profile img {
        width: 160px;
    }

    .phd-details {
        text-align: left;
    }

    /* Contact */
    .contact-card {
        flex-direction: column;
    }

    .contact-map {
        height: 260px;
        min-height: unset;
    }

    /* News */
    .news-card {
        flex-direction: column;
        gap: 15px;
    }

    .news-image img {
        max-width: 100%;
        width: 100%;
    }

    /* Typography scale-down */
    .lab-title {
        font-size: 1rem;
        letter-spacing: 1.5px;
    }

    section h2 {
        font-size: 1.2rem;
    }
}

/* =====================================================
   RESPONSIVE — SMALL MOBILE (≤ 480px)
===================================================== */
@media (max-width: 480px) {
    header {
    padding: 12px 14px;
    background: linear-gradient(to bottom, #ffffff 30%, #1d6fa5 100%);
}


    .header-logo img {
        max-width: 170px;
    }

    .header-iit-logo img {
        max-width: 85px;
    }

    .lab-title {
        font-size: 0.95rem;
        letter-spacing: 1.5px;
    }

    .lab-subtitle {
        font-size: 0.78rem;
        color: #555;
    }

    .card {
        padding: 14px;
        border-radius: 6px;
    }

    footer {
        font-size: 0.85rem;
        padding: 18px 12px;
    }
}





















