/* Main page css file */
    * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }

    :root {
        --primary-blue: #1e3a8a;
        --secondary-blue: #4b8df8;
        --accent-orange: #f97316;
        --accent-teal: #14b8a6;
        --dark-gray: #1f2937;
        --light-gray: #f8fafc;
        --medium-gray: #64748b;
        --white: #ffffff;
        --gradient-primary: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
        --gradient-accent: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
        --gradient-bg: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    }

    body {
        line-height: 1.6;
        color: var(--dark-gray);
        background: var(--gradient-bg);
        background-attachment: fixed;
    }

    .container {
        max-width: 1200px;
        margin: 0 auto;
        padding: 0 20px;
    }

    /* Hero Section */

    .hero {
        position: relative;
        overflow: hidden;
        color: white;
        padding: 80px 0 60px;
    }

    .hero {
        background: var(--gradient-primary);
        color: white;
        padding: 80px 0 60px; /* Reduced top and bottom padding */
        position: relative;
        overflow: hidden;
    }

    .hero-bg {
        position: absolute;
        inset: 0;

        width: 100%;
        height: 100%;

        object-fit: cover;
        object-position: center;

        z-index: 0;
    }

    .container {
        position: relative;
        z-index: 2;
    }

    .hero::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><defs><pattern id="grid" width="60" height="60" patternUnits="userSpaceOnUse"><path d="M 60 0 L 0 0 0 60" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
        opacity: 0.3;
    }

    .hero::after {
        content: '';
        position: absolute;
        top: 0; left: 0; right: 0; bottom: 0;
        background: linear-gradient(135deg, rgba(19, 62, 182, 0) 0%, rgba(41, 91, 230, 0) 100%);
        z-index: 1;
        pointer-events: none;
    }

    .hero-content {
        position: relative;
        z-index: 2;
        text-align: center;
        overflow: hidden;
        background: rgba(15, 70, 219, 0.45); 
        border-radius: 12px;
        padding: 48px 24px;
        display: inline-block;
        margin: auto;
        box-shadow: 0 8px 32px rgba(45, 83, 177, 0.4);
        backdrop-filter: blur(7px);
        -webkit-backdrop-filter: blur(7px);
    }

    .hero h1,
    .hero .tagline,
    .hero .subtitle {
        position: relative;
        z-index: 2;
        color: #fff;
        text-shadow: 0 6px 32px rgba(0,0,0,0.55), 0 2px 8px rgba(41,91,230,0.25);
    }

    .hero h1 {
        font-size: 4.5rem;
        font-weight: 750;
        margin-bottom: 1.2rem;
        line-height: 1.2;
        letter-spacing: 2px;
    }
    
    .hero .tagline {
        font-size: 1.7rem;
        margin-bottom: 0.7rem;
        font-weight: 400;
        opacity: 1;
    }

    .hero .subtitle {
        font-size: 1.25rem;
        margin-bottom: 3rem;
        opacity: 0.95;
        max-width: 700px;
        margin-left: auto;
        margin-right: auto;
    }

    .hero-cta {
        display: flex;
        gap: 1rem;
        justify-content: center;
        flex-wrap: wrap;
    }

    .btn-primary {
        background: var(--gradient-accent);
        color: white;
        padding: 1rem 2rem;
        text-decoration: none;
        border-radius: 50px;
        font-weight: 600;
        transition: all 0.3s ease;
        box-shadow: 0 10px 30px rgba(249, 115, 22, 0.3);
    }

    .btn-primary:hover {
        transform: translateY(-3px);
        box-shadow: 0 15px 40px rgba(249, 115, 22, 0.4);
    }

    .btn-secondary {
        background: rgba(60, 60, 60, 0.25);
        color: white;
        padding: 1rem 2rem;
        text-decoration: none;
        border-radius: 50px;
        font-weight: 600;
        border: 2px solid rgba(255, 255, 255, 0.3);
        transition: all 0.3s ease;
    }

    .btn-secondary:hover {
        background: rgba(255, 255, 255, 0.1);
        transform: translateY(-3px);
    }

    .btn-tertiary {
        background: rgba(255, 255, 255, 0.08);
        color: white;
        padding: 1rem 2rem;
        text-decoration: none;
        border-radius: 50px;
        font-weight: 600;
        border: 1.5px solid rgba(255, 255, 255, 0.35);
        transition: all 0.3s ease;
        backdrop-filter: blur(6px);
    }

    .btn-tertiary:hover {
        background: rgba(255, 255, 255, 0.18);
        border-color: rgba(255, 255, 255, 0.7);
        transform: translateY(-3px);
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    }

    /* Sections */
    section {
        padding: 80px 0;
    }

    .section-white {
        background: white;
        border-radius: 10px;
        margin: 2rem 0;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    }

    .section-title {
        text-align: center;
        font-size: 3rem;
        font-weight: 700;
        margin-bottom: 1rem;
        background: var(--gradient-primary);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }

    .section-subtitle {
        text-align: center;
        font-size: 1.2rem;
        color: var(--medium-gray);
        margin-bottom: 4rem;
        max-width: 600px;
        margin-left: auto;
        margin-right: auto;
    }

    /* Lab Overview */

    .lab-overview {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 4rem;
        align-items: center;
    }

    .lab-video {
        position: relative;
        background: var(--gradient-primary);
        border-radius: 0px;
        overflow: hidden;
        box-shadow: 0 20px 50px rgba(30, 58, 138, 0.3);
        min-width: 300px; /* Prevents it from shrinking too small */
    }

    .video-placeholder {
        aspect-ratio: 16/9;
        background: linear-gradient(135deg, #1e3a8a, #3b82f6);
        display: flex;
        align-items: center;
        justify-content: center;
        color: white;
        font-size: 1.2rem;
        position: relative;
    }

    .play-button {
        width: 80px;
        height: 80px;
        background: rgba(255, 255, 255, 0.2);
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.3s ease;
    }

    .lab-video video {
        cursor: pointer;
    }

    .lab-video::after {
        opacity: 0;
        transition: opacity 0.3s ease;
    }

    .lab-video:hover::after {
        opacity: 1;
    }

    .play-button:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: scale(1.1);
    }

    .play-button::after {
        content: '▶';
        font-size: 2rem;
        margin-left: 5px;
    }

    .lab-info h3 {
        font-size: 2.2rem;
        margin-bottom: 1.4rem;
        color: var(--primary-blue);
        font-weight: 700;
    }

    .lab-info p {
        margin-bottom: 1.5rem;
        font-size: 1.1rem;
        line-height: 1.8;
        color: var(--dark-gray);
    }

    .stats-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
        margin-top: 3rem;
    }

    .stat-item {
        text-align: center;
        padding: 1.5rem;
        background: var(--light-gray);
        border-radius: 15px;
    }

    .stat-number {
        font-size: 2.5rem;
        font-weight: 700;
        color: var(--accent-orange);
        display: block;
    }

    .stat-label {
        color: var(--medium-gray);
        font-weight: 500;
        margin-top: 0.5rem;
    }

    /* Featured Research */
    .research-showcase {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        gap: 2rem;
    }

    .research-card-link {
        text-decoration: none; /* no underline */
        color: inherit;        /* keep original text colors */
        display: block;        /* make the whole card clickable */
    }

    .research-card-link:hover .research-highlight {
        transform: translateY(-4px);
        box-shadow: 0 8px 16px rgba(0,0,0,0.15);
        transition: 0.3s ease;
    }


    .research-highlight {
        background: white;
        border-radius: 10px;
        overflow: hidden;
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
        transition: all 0.3s ease;
        border: 1px solid rgba(255, 255, 255, 0.2);
        height: 100%; 
    }

    .research-highlight:hover {
        transform: translateY(-10px);
        box-shadow: 0 25px 60px rgba(0, 0, 0, 0.15);
    }

    .research-image {
        height: 200px;
        background: var(--gradient-primary);
        display: flex;
        align-items: center;
        justify-content: center;
        color: white;
        font-size: 1.1rem;
        font-weight: 600;
    }

    .research-content {
        padding: 2rem;
    }

    .research-content h4 {
        font-size: 1.4rem;
        margin-bottom: 1rem;
        color: var(--primary-blue);
        font-weight: 700;
    }

    .research-content p {
        color: var(--medium-gray);
        line-height: 1.7;
        margin-bottom: 1rem;
    }

    .research-tags {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
        margin-top: 1rem;
    }

    .tag {
        background: rgba(249, 115, 22, 0.1);
        color: var(--accent-orange);
        padding: 0.3rem 0.8rem;
        border-radius: 20px;
        font-size: 0.8rem;
        font-weight: 500;
    }

    /* Recent Updates */
    .updates-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 1.5rem;
    }

    .update-card {
        background: white;
        padding: 2rem;
        border-radius: 15px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        border-left: 4px solid var(--accent-teal);
    }

    .update-date {
        color: var(--accent-teal);
        font-weight: 600;
        font-size: 0.9rem;
        margin-bottom: 0.5rem;
    }

    .update-card h4 {
        color: var(--primary-blue);
        margin-bottom: 1rem;
        font-size: 1.2rem;
    }

    .update-card p {
        color: var(--medium-gray);
        line-height: 1.6;
    }  

    .update-link {
        display: inline-block;
        color: #0056b3;
        text-decoration: none;
        font-weight: 500;
    }

    .update-link:hover {
        text-decoration: underline;
    }

    /* "More Details" Button */    
    .more-details-btn {
        display: inline-block;
        margin-top: 20px;
        padding: 10px 20px;
        background-color: #ff8f3f;   /* Button color */
        color: white;
        font-size: 16px;
        font-weight: bold;
        text-decoration: none;
        border-radius: 8px;
        transition: background-color 0.3s ease, transform 0.3s cubic-bezier(.4,2,.3,1);
        box-shadow: 0 10px 30px rgba(249, 115, 22, 0.15);
        text-align: center;
    }
    .more-details-btn:hover {
        background-color: #fa7000;   /* Darker on hover */
        transform: translateY(-3px);
        box-shadow: 0 15px 40px rgba(249, 115, 22, 0.25);
    }
    .more-details-container {
        text-align: center;         /* Centers the button */
        margin-top: 10px;
    }

    /* Animations */
    .animate-on-scroll {
        animation: fadeInUp 0.8s ease forwards;
    }

    /* Smooth scrolling */
    html {
        scroll-behavior: smooth;
    }

    .logo-icon[alt="IIT Kanpur Logo"] {
        background: #fff !important;
        padding: 6px;
        border-radius: 0px;
        box-shadow: 0 2px 8px rgba(30,58,138,0.08);
    }

    /* ========================================
    Desktop & Large Screens
    ======================================== */

    /* Extra large desktops (>1200px) */
    @media (min-width: 1201px) {
        .container {
            max-width: 1200px;
            padding: 0 20px;
        }
    }

    /* Medium desktops (1025px - 1200px) */
    @media (min-width: 1025px) and (max-width: 1200px) {
        .container { max-width: 1100px; padding: 0 18px; }
        .hero h1 { font-size: 4rem; }
        .hero .tagline { font-size: 1.5rem; }
        .hero .subtitle { font-size: 1.15rem; }
        .section-title { font-size: 2.7rem; }
        .section-subtitle { font-size: 1.1rem; }
        .research-showcase { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.8rem; }
        .research-content { padding: 1.8rem; }
    }

    /* Small desktops / large tablets (901px - 1024px) */
    @media (min-width: 901px) and (max-width: 1024px) {
        .container { max-width: 900px; padding: 0 16px; }
        .hero { padding: 70px 0 50px; }
        .hero h1 { font-size: 3.5rem; }
        .hero .tagline { font-size: 1.4rem; }
        .hero .subtitle { font-size: 1.1rem; }
        .hero-content { padding: 40px 20px; }
        section { padding: 70px 0; }
        .lab-overview { grid-template-columns: 1fr; gap: 3.5rem; }
        .section-title { font-size: 2.5rem; }
        .lab-info h3 { font-size: 2rem; }
        .lab-info p { font-size: 1.05rem; }
        .stats-grid { gap: 1.5rem; }
        .stat-number { font-size: 2.2rem; }
        .research-showcase { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.6rem; }
        .research-content { padding: 1.6rem; }
        .research-content h4 { font-size: 1.3rem; }
        .lab-video { max-width:500px; width:100%; margin:0 auto; } 
        .lab-video iframe { width:100%; height:auto; border-radius:0px; display:block; }
    }

    /* Medium tablets (769px - 900px) */
    @media (min-width: 769px) and (max-width: 900px) {
        .container { padding: 0 15px; }
        .hero { padding: 65px 0 45px; }
        .hero h1 { font-size: 3rem; }
        .hero .tagline { font-size: 1.3rem; }
        .hero .subtitle { font-size: 1rem; }
        .hero-content { padding: 40px 20px; }
        section { padding: 65px 0; }
        .section-title { font-size: 2.2rem; }
        .section-subtitle { font-size: 1rem; }
        .lab-overview { grid-template-columns: 1fr; gap: 3rem; }
        .lab-video { max-width:500px; width:100%; margin:0 auto; } 
        .lab-video iframe { width:100%; height:auto; border-radius:0px; display:block; }
        .lab-info h3 { font-size: 1.8rem; }
        .stats-grid { gap: 1.3rem; }
        .research-showcase { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.4rem; }
        .research-image { height: 190px; }
        .research-content { padding: 1.4rem; }
    }

    /* Small tablets (601px - 768px) */
    @media (min-width: 601px) and (max-width: 768px) {
        .container { padding: 0 12px; }
        .hero h1 { font-size: 2.8rem; }
        .hero .tagline { font-size: 1.4rem; }
        .hero-content { padding: 40px 20px; margin: 0 1rem; }
        section { padding: 60px 0; }
        .section-title { font-size: 2rem; }
        .lab-overview { grid-template-columns: 1fr; gap: 2.5rem; }
        .lab-info h3 { font-size: 1.7rem; }
        .stats-grid { grid-template-columns: repeat(3, 1fr); gap: 1rem; }
        .research-showcase { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.2rem; }
        .updates-grid { grid-template-columns: repeat(2, 1fr); gap: 1.2rem; }
        .lab-video { max-width:500px; width:100%; margin:0 auto; } 
        .lab-video iframe { width:100%; height:auto; border-radius:0px; display:block; }        }

    /* ========================================
    Mobile & Extra Small Screens
    ======================================== */

    /* Mobile (up to 600px) */
    @media (max-width: 600px) {
        .hero { padding: 80px 0 40px; }
        .hero-content { padding: 36px 18px; margin: 0 1rem; }
        .hero h1 { font-size: 2.5rem; line-height: 1.1; margin-bottom: 1rem; }
        .hero .tagline { font-size: 1.3rem; margin-bottom: 0.5rem; }
        .hero .subtitle { font-size: 1.1rem; margin-bottom: 2rem; }
        .hero-cta { flex-direction: column; align-items: center; gap: 0.8rem; }
        .btn-primary, .btn-secondary, .btn-tertiary { width: 200px; padding: 0.8rem 1.5rem; font-size: 0.9rem; text-align: center; }
        section { padding: 50px 0; }
        .container { padding: 0 20px; }
        .section-white { margin: 1rem 0; border-radius: 10px; }
        .section-title { font-size: 2rem; margin-bottom: 0.8rem; }
        .lab-info h3 { font-size: 1.6rem; }
        .lab-info p { font-size: 1rem; }
        .section-subtitle { font-size: 1rem; margin-bottom: 2.5rem; padding: 0 1rem; }
        .lab-overview, .research-showcase, .updates-grid { grid-template-columns: 1fr; gap: 1.5rem; }
        .stats-grid { display: flex; flex-wrap: wrap;gap: 1rem; justify-content: center; }
        .research-image { height: 180px; }
        .research-content { padding: 1.5rem; }
        .research-content h4 { font-size: 1.2rem; margin-bottom: 0.8rem; }
        .research-content h5 { font-size: 1rem; margin-bottom: 0.8rem; }
        .research-content p { font-size: 0.9rem; line-height: 1.6; }
        .research-tags { margin-top: 0.8rem; }
        .tag { padding: 0.25rem 0.6rem; font-size: 0.75rem; }
        .update-card { padding: 1.5rem; }
        .update-card h4 { font-size: 1.1rem; margin-bottom: 0.8rem; }
        .update-card p { font-size: 0.9rem; line-height: 1.5; }
        .more-details-btn { padding: 12px 24px; font-size: 14px; margin-top: 1.5rem; }
        .lab-video { max-width:500px; width:100%; margin:0 auto; } 
        .lab-video iframe { width:100%; height:auto; border-radius:0px; display:block; }  
        .stat-item { padding: 1rem; }
        .stat-number { font-size: 1.8rem; }
        .stat-label { font-size: 0.85rem; }          
        html { scroll-padding-top: 80px; }
    }

    /* Extra small mobile (up to 480px) */
    @media (max-width: 480px) {
        .hero h1 { font-size: 2.25rem; }
        .hero .tagline { font-size: 1rem; }
        .hero .subtitle { font-size: 0.9rem; }
        .hero-content { padding: 20px 12px; margin: 0 0.5rem; }
        .section-title { font-size: 1.8rem; }
        .section-subtitle { font-size: 0.9rem; padding: 0 0.5rem; }
        .research-content { padding: 1rem; }
        .research-image { height: 160px; }
    }

    /* Animations */
    @keyframes fadeInUp {
        from {
            opacity: 0;
            transform: translateY(30px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

