

        /* Page Header */
        .page-header {
            padding: 8rem 5% 4rem;
            background: linear-gradient(135deg, #f5f7fa 0%, #e4edf9 100%);
            text-align: center;
            position: relative;
            overflow: hidden;
        }

        .page-header::before {
            content: '';
            position: absolute;
            top: -50px;
            right: -50px;
            width: 300px;
            height: 300px;
            border-radius: 50%;
            background: rgba(59, 130, 246, 0.1);
            animation: float 6s ease-in-out infinite;
        }

        .page-header::after {
            content: '';
            position: absolute;
            bottom: -100px;
            left: -100px;
            width: 400px;
            height: 400px;
            border-radius: 50%;
            background: rgba(16, 185, 129, 0.1);
            animation: float 8s ease-in-out infinite reverse;
        }

        @keyframes float {
            0% { transform: translateY(0) rotate(0deg); }
            50% { transform: translateY(-20px) rotate(10deg); }
            100% { transform: translateY(0) rotate(0deg); }
        }

        .page-header h1 {
            font-size: 3rem;
            color: var(--dark);
            margin-bottom: 1rem;
            position: relative;
            z-index: 1;
        }

        .page-header p {
            font-size: 1.2rem;
            color: var(--gray);
            max-width: 700px;
            margin: 0 auto;
            position: relative;
            z-index: 1;
        }

        /* Subject Categories */
        .subject-categories {
            padding: 3rem 5%;
            background: white;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
            position: relative;
            z-index: 5;
        }

        .categories-container {
            max-width: 1200px;
            margin: 0 auto;
        }

        .categories-title {
            text-align: center;
            margin-bottom: 2rem;
        }

        .categories-title h2 {
            font-size: 2rem;
            color: var(--dark);
            margin-bottom: 0.5rem;
        }

        .category-tabs {
            display: flex;
            justify-content: center;
            flex-wrap: wrap;
            gap: 1rem;
            margin-bottom: 2rem;
        }

        .category-tab {
            padding: 0.8rem 1.5rem;
            background: var(--light);
            border: 2px solid var(--light-gray);
            border-radius: 30px;
            font-weight: 600;
            color: var(--gray);
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .category-tab:hover {
            border-color: var(--primary);
            color: var(--primary);
        }

        .category-tab.active {
            background: var(--primary);
            color: white;
            border-color: var(--primary);
        }

        /* Subjects Grid - Equal Height Cards */
        .subjects-section {
            padding: 4rem 5%;
            max-width: 1200px;
            margin: 0 auto;
        }

        .subjects-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
            gap: 2rem;
            margin-bottom: 3rem;
            align-items: stretch; /* This makes all cards stretch to equal height */
        }

        .subject-card {
            background: white;
            border-radius: 12px;
            overflow: hidden;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
            transition: all 0.3s ease;
            animation: fadeInUp 0.6s ease forwards;
            opacity: 0;
            position: relative;
            display: flex;
            flex-direction: column; /* This allows the card to expand */
        }

        .subject-card:nth-child(1) { animation-delay: 0.1s; }
        .subject-card:nth-child(2) { animation-delay: 0.2s; }
        .subject-card:nth-child(3) { animation-delay: 0.3s; }
        .subject-card:nth-child(4) { animation-delay: 0.4s; }
        .subject-card:nth-child(5) { animation-delay: 0.5s; }
        .subject-card:nth-child(6) { animation-delay: 0.6s; }
        .subject-card:nth-child(7) { animation-delay: 0.7s; }
        .subject-card:nth-child(8) { animation-delay: 0.8s; }

        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(20px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .subject-card:hover {
            transform: translateY(-10px);
            box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
        }

        .subject-header {
            padding: 2rem;
            text-align: center;
            background: linear-gradient(135deg, var(--primary), var(--secondary));
            color: white;
            position: relative;
            overflow: hidden;
        }

        .subject-header::before {
            content: '';
            position: absolute;
            top: -50%;
            right: -50%;
            width: 200%;
            height: 200%;
            background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 70%);
            animation: pulse 4s ease-in-out infinite;
        }

        @keyframes pulse {
            0%, 100% { transform: scale(1); opacity: 0.5; }
            50% { transform: scale(1.1); opacity: 0.3; }
        }

        .subject-icon {
            font-size: 3.5rem;
            margin-bottom: 1rem;
            position: relative;
            z-index: 1;
        }

        .subject-name {
            font-size: 1.5rem;
            font-weight: 700;
            margin-bottom: 0.5rem;
            position: relative;
            z-index: 1;
        }

        .subject-levels {
            font-size: 0.9rem;
            opacity: 0.9;
            position: relative;
            z-index: 1;
        }

        .subject-body {
            padding: 2rem;
            flex: 1; /* This makes the body expand to fill available space */
            display: flex;
            flex-direction: column;
        }

        .subject-description {
            color: var(--gray);
            margin-bottom: 1.5rem;
            line-height: 1.6;
            flex: 1; /* This makes the description expand */
        }

        .subject-topics {
            margin-bottom: 1.5rem;
        }

        .subject-topics h4 {
            font-size: 1rem;
            color: var(--dark);
            margin-bottom: 0.8rem;
        }

        .topics-list {
            display: flex;
            flex-wrap: wrap;
            gap: 0.5rem;
        }

        .topic-tag {
            padding: 0.3rem 0.8rem;
            background: var(--light);
            border-radius: 20px;
            font-size: 0.85rem;
            color: var(--gray);
            transition: all 0.3s ease;
        }

        .topic-tag:hover {
            background: var(--primary);
            color: white;
        }

        .subject-stats {
            display: flex;
            justify-content: space-between;
            margin-bottom: 1.5rem;
            padding-top: 1rem;
            border-top: 1px solid var(--light-gray);
        }

        .stat-item {
            text-align: center;
        }

        .stat-number {
            font-size: 1.5rem;
            font-weight: 700;
            color: var(--primary);
        }

        .stat-label {
            font-size: 0.85rem;
            color: var(--gray);
        }

        .subject-actions {
            display: flex;
            gap: 1rem;
            margin-top: auto; /* This pushes the buttons to the bottom */
        }

        .btn-find-tutor {
            flex: 1;
            padding: 0.8rem;
            background: var(--primary);
            color: white;
            border: none;
            border-radius: 6px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            text-align: center;
        }

        .btn-find-tutor:hover {
            background: var(--secondary);
            transform: translateY(-2px);
        }

        .btn-learn-more {
            flex: 1;
            padding: 0.8rem;
            background: var(--light);
            color: var(--primary);
            border: 2px solid var(--primary);
            border-radius: 6px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            text-align: center;
        }

        .btn-learn-more:hover {
            background: var(--primary);
            color: white;
        }

        /* Featured Section - Equal Height Cards */
        .featured-section {
            padding: 4rem 5%;
            background: white;
            margin-top: 3rem;
        }

        .featured-container {
            max-width: 1200px;
            margin: 0 auto;
        }

        .featured-title {
            text-align: center;
            margin-bottom: 3rem;
        }

        .featured-title h2 {
            font-size: 2.5rem;
            color: var(--dark);
            margin-bottom: 1rem;
        }

        .featured-title p {
            color: var(--gray);
            max-width: 700px;
            margin: 0 auto;
        }

        .featured-subjects {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
            gap: 2rem;
            align-items: stretch; /* This makes all cards stretch to equal height */
        }

        .featured-subject {
            background: var(--light);
            border-radius: 12px;
            padding: 2rem;
            text-align: center;
            transition: all 0.3s ease;
            position: relative;
            overflow: hidden;
            display: flex;
            flex-direction: column; /* This allows the card to expand */
        }

        .featured-subject::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 5px;
            background: linear-gradient(90deg, var(--primary), var(--secondary));
            transform: scaleX(0);
            transform-origin: left;
            transition: transform 0.3s ease;
        }

        .featured-subject:hover::before {
            transform: scaleX(1);
        }

        .featured-subject:hover {
            transform: translateY(-10px);
            box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
        }

        .featured-icon {
            font-size: 3rem;
            color: var(--primary);
            margin-bottom: 1rem;
        }

        .featured-subject h3 {
            font-size: 1.3rem;
            color: var(--dark);
            margin-bottom: 1rem;
        }

        .featured-subject p {
            color: var(--gray);
            margin-bottom: 1.5rem;
            flex: 1; /* This makes the description expand */
        }

        .featured-btn {
            display: inline-block;
            padding: 0.6rem 1.5rem;
            background: var(--primary);
            color: white;
            border-radius: 6px;
            font-weight: 600;
            text-decoration: none;
            transition: all 0.3s ease;
            margin-top: auto; /* This pushes the button to the bottom */
        }

        .featured-btn:hover {
            background: var(--secondary);
            transform: translateY(-2px);
        }

        /* CTA Section */
        .cta-section {
            padding: 4rem 5%;
            background: linear-gradient(135deg, var(--primary), var(--secondary));
            color: white;
            text-align: center;
            margin-top: 3rem;
        }

        .cta-content {
            max-width: 800px;
            margin: 0 auto;
        }

        .cta-content h2 {
            font-size: 2.5rem;
            margin-bottom: 1rem;
        }

        .cta-content p {
            font-size: 1.2rem;
            margin-bottom: 2rem;
            opacity: 0.9;
        }

        .btn-cta {
            display: inline-block;
            padding: 1rem 2.5rem;
            background: white;
            color: var(--primary);
            border-radius: 50px;
            font-weight: 600;
            font-size: 1.1rem;
            text-decoration: none;
            transition: all 0.3s ease;
            box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
        }

        .btn-cta:hover {
            transform: translateY(-5px);
            box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
        }

        /* Footer - Equal Height Columns */
        footer {
            background: var(--dark);
            color: white;
            padding: 4rem 5% 2rem;
            margin-top: 5rem;
        }

        .footer-content {
            display: flex;
            flex-wrap: wrap;
            justify-content: space-between;
            max-width: 1200px;
            margin: 0 auto;
            gap: 2rem;
            align-items: stretch; /* This makes all columns stretch to equal height */
        }

        .footer-column {
            flex: 1;
            min-width: 250px;
            display: flex;
            flex-direction: column; /* This allows the column to expand */
        }

        .footer-column h3 {
            font-size: 1.3rem;
            margin-bottom: 1.5rem;
            color: var(--accent);
            position: relative;
            padding-bottom: 0.5rem;
        }

        .footer-column h3::after {
            content: '';
            position: absolute;
            bottom: 0;
            left: 0;
            width: 40px;
            height: 2px;
            background: var(--accent);
        }

        .footer-column p {
            margin-bottom: 1.5rem;
            color: #cbd5e1;
            line-height: 1.8;
        }

        .footer-column ul {
            list-style: none;
            margin-bottom: auto; /* This pushes the content to the top */
        }

        .footer-column ul li {
            margin-bottom: 0.8rem;
        }

        .footer-column ul li a {
            color: #cbd5e1;
            text-decoration: none;
            transition: all 0.3s ease;
            display: inline-block;
            position: relative;
        }

        .footer-column ul li a:hover {
            color: var(--accent);
            padding-left: 5px;
        }

        .social-icons {
            display: flex;
            gap: 1rem;
            margin-top: auto; /* This pushes the social icons to the bottom */
        }

        .social-icons a {
            display: flex;
            align-items: center;
            justify-content: center;
            width: 40px;
            height: 40px;
            border-radius: 50%;
            background: rgba(255, 255, 255, 0.1);
            color: white;
            transition: all 0.3s ease;
        }

        .social-icons a:hover {
            background: var(--accent);
            transform: translateY(-5px);
        }

        .copyright {
            text-align: center;
            padding-top: 2rem;
            margin-top: 2rem;
            border-top: 1px solid rgba(255, 255, 255, 0.1);
            color: #94a3b8;
            font-size: 0.9rem;
        }

        /* Responsive Design */
        @media (max-width: 992px) {
            .subjects-grid {
                grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            }
        }

        @media (max-width: 768px) {
            .nav-links, .cta-buttons {
                display: none;
            }
            
            .menu-toggle {
                display: flex;
            }
            
            .page-header h1 {
                font-size: 2.2rem;
            }
            
            .category-tabs {
                justify-content: flex-start;
                overflow-x: auto;
                padding-bottom: 0.5rem;
            }
            
            .subjects-grid {
                grid-template-columns: 1fr;
            }
            
            .featured-subjects {
                grid-template-columns: 1fr;
            }
            
            .footer-content {
                flex-direction: column;
                gap: 2rem;
            }
        }

        /* Mobile Menu Animation */
        @media (max-width: 768px) {
            .nav-links.active, .cta-buttons.active {
                display: flex;
                flex-direction: column;
                position: absolute;
                top: 100%;
                left: 0;
                width: 100%;
                background: white;
                padding: 1rem;
                box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
                animation: slideDown 0.5s ease;
            }
            
            @keyframes slideDown {
                from {
                    opacity: 0;
                    transform: translateY(-20px);
                }
                to {
                    opacity: 1;
                    transform: translateY(0);
                }
            }
            
            .nav-links.active {
                top: 60px;
            }
            
            .cta-buttons.active {
                top: 280px;
            }
            
            .nav-links.active li {
                margin: 0.8rem 0;
            }
            
            .cta-buttons.active {
                gap: 0.8rem;
            }
        }
