        :root {
            --primary: #8e44ad;
            --secondary: #3498db;
            --light: #fdfdfd;
            --dark: #ecf0f1;
            --text: #ecf0f1;
            --bg: #2c3e50;
            --card-bg: #34495e;
            --footer-bg: #1a2530;
            --shadow: rgba(0, 0, 0, 0.3);
            --subject-card-bg: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
            --testimonial-bg: rgba(0, 0, 0, 0.2);
            --accent: #e74c3c;
            --transition: all 0.4s ease;
        }
        
        html, body {
            width: 100%;
            overflow-x: hidden;
        }

        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            color: var(--text);
            background-color: var(--bg);
            transition: var(--transition);
        }

        /* Navbar */
        .navbar {
            background-color: rgba(0, 0, 0, 0.2);
            backdrop-filter: blur(10px);
            -webkit-backdrop-filter: blur(10px);
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
            box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
            padding: 15px 0;
            transition: var(--transition);
        }

        .navbar-brand {
            font-weight: 700;
            color: var(--light) !important;
            font-size: 1.5rem;
            text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
        }
        
        .nav-link {
            color: var(--light) !important;
            font-weight: 500;
            margin: 0 10px;
            transition: var(--transition);
        }
        
        .nav-link:hover {
            color: var(--secondary) !important;
            transform: translateY(-2px);
        }
        
        .navbar-collapse {
            transition: height 0.3s ease-in-out;
        }

        /* make the hamburger icon white */
        .navbar-toggler {
            border-color: white; /* optional: removes border */
            color: rgb(0 0 0 / 0%);
        }

        /* Make the toggler icon white */
        .navbar-toggler-icon {
            background-image: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='white' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
        }

        /* Hero Section */
        .hero {
            background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
            color: white;
            padding: 120px 0 100px;
            position: relative;
            overflow: hidden;
        }
        .hero-content { position: relative; z-index: 2; }
        .hero h1 { font-size: 3.5rem; font-weight: 800; margin-bottom: 20px; }
        .hero p { font-size: 1.25rem; margin-bottom: 30px; }
        
        /* General Components */
        .section-title {
            position: relative;
            margin-bottom: 40px;
            font-weight: 700;
            color: var(--light);
        }
        .section-title:after {
            content: '';
            display: block;
            width: 60px;
            height: 4px;
            background: var(--secondary);
            margin: 15px auto 0;
        }
        .card {
            border: none;
            border-radius: 10px;
            overflow: hidden;
            transition: var(--transition);
            box-shadow: 0 10px 20px var(--shadow);
            margin-bottom: 20px;
            background-color: var(--card-bg);
        }
        .card:hover {
            transform: translateY(-10px);
            box-shadow: 0 15px 30px var(--shadow);
        }
        .btn-primary {
            background-color: var(--secondary);
            border: none;
            padding: 12px 30px;
            font-weight: 600;
            transition: var(--transition);
        }
        .btn-primary:hover {
            background-color: var(--primary);
            transform: translateY(-3px);
            box-shadow: 0 5px 15px var(--shadow);
        }
        .btn-outline-primary {
            border-color: var(--secondary);
            color: var(--secondary);
            transition: var(--transition);
        }
        .btn-outline-primary:hover {
            background-color: var(--secondary);
            color: white;
            transform: translateY(-3px);
            box-shadow: 0 5px 15px var(--shadow);
        }

        /* Specific Sections */
        .about-card {
            background-color: var(--card-bg);
            padding: 40px;
            border-radius: 15px;
            box-shadow: 0 10px 20px var(--shadow);
            transition: var(--transition);
        }
        .about-card img {
            max-width: 200px;
            border-radius: 50%;
            margin-bottom: 20px;
            border: 5px solid var(--secondary);
            object-fit: cover;
        }
        .service-card {
            background-color: var(--card-bg);
            border-radius: 10px;
            padding: 25px;
            box-shadow: 0 5px 15px var(--shadow);
            height: 100%;
            transition: var(--transition);
            text-align: center;
        }
        .service-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 10px 25px var(--shadow);
        }
        .service-card i {
            font-size: 3rem;
            color: var(--accent);
            margin-bottom: 20px;
        }
        .subject-card {
            background: var(--subject-card-bg);
            padding: 30px;
            height: 100%;
            border-left: 5px solid var(--secondary);
        }
        .subject-card i {
            font-size: 2.5rem;
            color: var(--secondary);
            margin-bottom: 20px;
        }
        .experiment-showcase {
            position: relative;
            overflow: hidden;
            border-radius: 10px;
            height: 300px;
            margin-bottom: 30px;
        }
        .experiment-video {
            width: 100%;
            height: 100%;
            object-fit: cover;
            transition: var(--transition);
        }
        .experiment-overlay {
            position: absolute;
            bottom: 0; left: 0; right: 0;
            background: rgba(0, 0, 0, 0.7);
            padding: 20px;
            color: white;
            transform: translateY(100%);
            transition: var(--transition);
        }
        .experiment-showcase:hover .experiment-overlay { transform: translateY(0); }
        .experiment-showcase:hover .experiment-video { transform: scale(1.05); }

        .why-join-us i {
            font-size: 1.5rem;
            color: var(--secondary);
        }
        .course-btn {
            background-color: #343a40;
            border: 2px solid var(--secondary);
            color: #fcfeff;
            border-radius: 10px;
            padding: 15px;
            text-align: center;
            height: 100%;
            transition: var(--transition);
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            text-decoration: none;
        }
        .course-btn:hover {
            background-color: var(--secondary);
            color: white;
            transform: translateY(-5px);
            box-shadow: 0 10px 25px var(--shadow);
        }
        .course-btn i {
            font-size: 2rem;
            margin-bottom: 10px;
        }
        .testimonials {
            background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
            color: white;
            padding: 80px 0;
        }
        .testimonial-card {
            background: var(--testimonial-bg);
            backdrop-filter: blur(10px);
            border-radius: 15px;
            padding: 30px;
            margin: 20px 0;
        }
        .testimonial-card:hover {
            transform: translateY(-5px);
            background: rgba(255, 255, 255, 0.15);
        }
        .contact {
            padding: 80px 0;
            background-color: #34495e;
        }

        /* Periodic Table */
        .periodic-table-container {
            overflow-x: auto;
            padding: 20px;
            background-color: var(--card-bg);
            border-radius: 10px;
            box-shadow: 0 10px 20px var(--shadow);
            margin-bottom: 30px;
            -webkit-overflow-scrolling: touch;
        }
        .periodic-table-grid {
            display: grid;
            grid-template-columns: repeat(18, 1fr);
            gap: 4px;
            min-width: 800px;
        }
        .element {
            width: 100%;
            padding-bottom: 100%;
            position: relative;
            font-weight: bold;
            border-radius: 5px;
            cursor: pointer;
            transition: var(--transition);
            box-shadow: 0 3px 6px var(--shadow);
            color: #000;
            font-size: clamp(0.5rem, 2.5vw, 1rem);
        }
        .element-content {
            position: absolute;
            top: 0; left: 0;
            width: 100%; height: 100%;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            line-height: 1;
        }
        .element-symbol { font-size: clamp(0.6rem, 2vw, 1.2rem); }
        .element-number {
            font-size: clamp(0.4rem, 1.5vw, 0.7rem);
            position: absolute;
            top: 5px; left: 5px;
        }
        .element:hover { transform: scale(1.2); z-index: 10; }
        .alkali-metal { background-color: #ff8a80; }
        .alkaline-earth-metal { background-color: #ffcc80; }
        .lanthanide { background-color: #d1c4e9; }
        .actinide { background-color: #b39ddb; }
        .transition-metal { background-color: #80deea; }
        .post-transition-metal { background-color: #a5d6a7; }
        .metalloid { background-color: #ce93d8; }
        .polyatomic-nonmetal, .diatomic-nonmetal { background-color: #fff59d; }
        .halogen { background-color: #90caf9; }
        .noble-gas { background-color: #f48fb1; }
        .unknown { background-color: #e0e0e0; }

        /* Animations */
        .particles-container {
            position: absolute;
            top: 0; left: 0;
            width: 100%; height: 100%;
            z-index: 1;
            overflow: hidden;
        }
        .particle {
            position: absolute;
            border-radius: 50%;
            opacity: 0.5;
            animation: float-particle 15s infinite linear;
        }
        @keyframes float-particle {
            0% { transform: translateY(0) translateX(0) rotate(0deg); }
            100% { transform: translateY(-1000px) translateX(500px) rotate(720deg); }
        }

        .molecule-structure {
            width: 100%;
            height: 200px;
            background: var(--bg);
            border-radius: 10px;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-bottom: 20px;
            position: relative;
            overflow: hidden;
        }
        .atom {
            position: absolute;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-weight: bold;
            font-size: 14px;
        }
        .electron {
            position: absolute;
            border-radius: 50%;
            background-color: #fff;
            box-shadow: 0 0 10px var(--secondary);
            animation-name: electron-rotate;
            animation-timing-function: linear;
            animation-iteration-count: infinite;
        }
        @keyframes electron-rotate {
            from { transform: rotate(0deg) translateX(var(--radius, 40px)) rotate(0deg); }
            to   { transform: rotate(360deg) translateX(var(--radius, 40px)) rotate(-360deg); }
        }

        .concept-visualization {
            padding: 20px;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-direction: column;
            overflow: hidden;
        }
        /* Bohr Model */
        #bohr-model-container {
            position: relative;
            width: 150px;
            height: 150px;
            margin: auto;
        }
        .nucleus {
            position: absolute;
            width: 40px;
            height: 40px;
            background: #e74c3c;
            border-radius: 50%;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-weight: bold;
            z-index: 2;
        }
        .electron-shell {
            position: absolute;
            border: 2px solid var(--text);
            border-radius: 50%;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            z-index: 1;
        }
        .electron-particle {
            position: absolute;
            width: 10px;
            height: 10px;
            background: var(--secondary);
            border-radius: 50%;
            top: 50%;
            left: 50%;
            margin: -5px;
        }
        @keyframes orbit {
            from { transform: rotate(0deg) translateX(var(--radius)) rotate(0deg); }
            to   { transform: rotate(360deg) translateX(var(--radius)) rotate(-360deg); }
        }

        /* Bonding Diagram */
        #bonding-container {
            display: flex;
            justify-content: space-around;
            width: 100%;
            font-size: 12px;
        }
        .bond-diagram {
            position: relative;
            width: 120px;
            height: 100px;
        }
        .atom-node {
            position: absolute;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-weight: bold;
        }
        .bond-line {
            position: absolute;
            background: var(--text);
            height: 2px;
            transform-origin: left center;
        }
        .electron-transfer {
            position: absolute;
            width: 8px;
            height: 8px;
            background: yellow;
            border-radius: 50%;
            animation: transfer 2s ease-in-out infinite;
        }
        @keyframes transfer {
            from { left: 20px; opacity: 1; }
            to   { left: 80px; opacity: 0; }
        }

        /* pH Scale */
        #ph-scale-container {
            width: 100%;
            padding: 0 10px;
        }
        .ph-scale {
            display: flex;
            width: 100%;
            height: 30px;
            border-radius: 5px;
            overflow: hidden;
            background: linear-gradient(to right, #e74c3c, #f1c40f, #2ecc71, #3498db, #9b59b6);
        }
        .ph-labels {
            display: flex;
            justify-content: space-between;
            width: 100%;
            margin-top: 5px;
            font-size: 12px;
            font-weight: bold;
        }
        
        /* Footer */
        .text-muted {
            --bs-text-opacity: 1;
            color: rgb(190 190 190 / 75%) !important;
        }
        footer {
            background-color: var(--footer-bg);
            color: white;
            padding: 40px 0 20px;
            transition: all 0.4s ease;
        }
        .social-links a {
            color: white;
            font-size: 1.5rem;
            margin: 0 10px;
            transition: all 0.4s ease;
        }
        .social-links a:hover {
            color: var(--secondary);
            transform: translateY(-5px);
        }

        /* Responsive adjustments */
        /* Styles for mobile navbar (when it's collapsed) */
        @media (max-width: 991.98px) {
            .navbar-collapse {
                background: var(--card-bg);
                border-radius: 10px;
                padding: 10px;
                margin-top: 10px;
                box-shadow: 0 5px 15px var(--shadow);
            }
            .navbar-nav .nav-item {
                text-align: center;
            }
            .navbar-nav .dropdown-menu {
                background-color: transparent;
                border: none;
                box-shadow: none;
                text-align: center;
            }
        }
        
        @media (max-width: 768px) {
            body {
                text-align: center;
            }
            .hero h1 { font-size: 2.5rem; }
            .hero p { font-size: 1rem; }
            .section-title { font-size: 1.8rem; }
            .section-title:after {
                margin: 15px auto 0;
            }
            .about-card { padding: 25px; }
            .about-card img { max-width: 150px; }
            .contact .col-md-6:first-child {
                margin-bottom: 30px;
            }
            footer .text-md-start {
                text-align: center !important;
            }
            .social-links {
                margin-bottom: 20px;
            }
            
            .periodic-table-container {
                position: relative;
            }
            .periodic-table-container::after {
                content: 'Swipe to explore →';
                position: absolute;
                bottom: 5px;
                right: 15px;
                background-color: rgba(255,255,255,0.1);
                padding: 2px 8px;
                border-radius: 5px;
                font-size: 0.7rem;
                color: var(--text);
                animation: pulse 2s infinite;
                z-index: 5;
            }
            @keyframes pulse {
                0% { opacity: 1; }
                50% { opacity: 0.5; }
                100% { opacity: 1; }
            }
            .periodic-table-grid { gap: 2px; }
        }
        
        @media (max-width: 480px) {
            .hero h1 { font-size: 1.8rem; }
            .hero p { font-size: 0.9rem; }
            
            .course-btn {
                padding: 10px;
                font-size: 0.9rem;
            }
            .course-btn i {
                font-size: 1.5rem;
                margin-bottom: 5px;
            }

            .subject-card, .service-card, .about-card {
                padding: 20px;
            }

            .molecule-structure {
                height: 180px; 
            }

            #bohr-model-container {
                width: 140px;
                height: 140px;
            }

            .periodic-table-container::after {
                font-size: 0.6rem;
                padding: 2px 6px;
                bottom: 3px;
                right: 10px;
            }
        }
        
        