/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', 'Noto Sans Sinhala', sans-serif;
    color: #333;
    background-color: #fafbfc;
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* Colors */
:root {
    --primary-color: #0056b3;
    --secondary-color: #fd7e14;
    --accent-color: #e9ecef;
    --text-color: #333;
    --light-bg: #fff;
    --green-whatsapp: #25D366;
}

/* Typography */
h1, h2, h3, h4 {
    font-family: 'Noto Sans Sinhala', sans-serif;
    font-weight: 800;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    border: 2px solid var(--primary-color);
}

.btn-primary:hover {
    background-color: transparent;
    color: var(--primary-color);
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn-whatsapp {
    background-color: var(--green-whatsapp);
    color: white;
    font-size: 1.2rem;
    padding: 15px 35px;
    border-radius: 50px;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
}

.btn-whatsapp:hover {
    background-color: #128C7E;
    transform: translateY(-3px);
}

/* Header & Navigation */
header {
    background-color: var(--light-bg);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
}

.logo img {
    height: 70px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 25px;
}

.nav-links li a {
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--text-color);
    transition: color 0.3s ease;
    padding: 5px;
}

.nav-links li a:hover {
    color: var(--primary-color);
}

/* Mobile Nav Burger */
.burger {
    display: none;
    cursor: pointer;
}

.burger div {
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    margin: 5px;
    transition: all 0.3s ease;
}

/* Hero Section */
.hero {
    padding: 60px 0;
    background: linear-gradient(135deg, #fdfbfb 0%, #ebedee 100%);
    overflow: hidden;
}

.hero-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.hero-content {
    flex: 1;
}

.hero-content h1 {
    font-size: 3rem;
    color: var(--text-color);
    line-height: 1.3;
    margin-bottom: 20px;
}

.hero-content h1 span {
    color: var(--primary-color);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    color: #555;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.hero-image {
    flex: 1;
    position: relative;
    display: flex;
    justify-content: center;
}

.image-bg-shape {
    position: absolute;
    width: 350px;
    height: 350px;
    background-color: var(--secondary-color);
    border-radius: 50%;
    z-index: 1;
    opacity: 0.15;
    top: 50%;
    transform: translateY(-50%);
}

.hero-image img {
    max-width: 100%;
    z-index: 2;
    position: relative;
    /* max-height: 500px; */
}

/* About Section */
.about {
    padding: 80px 0;
    background-color: white;
}

.about-container {
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-image {
    flex: 1;
    background: #eef2f5;
    border-radius: 20px;
    text-align: center;
    padding-top: 20px;
}

.about-image img {
    max-width: 90%;
    max-height: 400px;
}

.about-content {
    flex: 1;
}

.about-content h2 {
    font-size: 2.2rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.about-content p {
    font-size: 1.1rem;
    margin-bottom: 25px;
}

.features li {
    font-size: 1.1rem;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.features li i {
    color: var(--secondary-color);
    font-size: 1.3rem;
}

/* Classes Section */
.classes {
    padding: 80px 0;
    background-color: #f4f7f6;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
    color: var(--primary-color);
}

.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.class-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    overflow: hidden;
    transition: transform 0.3s ease;
    border-top: 5px solid;
}

.class-card:hover {
    transform: translateY(-10px);
}

.class-card.grade-3 { border-top-color: #ffca28; }
.class-card.grade-4 { border-top-color: #42a5f5; }
.class-card.grade-5 { border-top-color: #66bb6a; }

.card-header {
    padding: 20px;
    text-align: center;
    background-color: #fafbfc;
    border-bottom: 1px solid #eee;
}

.card-header h3 {
    font-size: 1.8rem;
    color: var(--text-color);
}

.card-body {
    padding: 25px;
}

.class-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 20px;
}

.class-item:last-child {
    margin-bottom: 0;
}

.class-item .icon {
    font-size: 1.5rem;
    color: var(--primary-color);
    background: var(--accent-color);
    padding: 12px;
    border-radius: 50%;
}

.class-details h4 {
    font-size: 1.1rem;
    color: #333;
    margin-bottom: 5px;
}

.class-details p {
    color: #666;
    font-size: 0.95rem;
    font-weight: 500;
}

/* Motivation Section */
.motivation {
    padding: 80px 0;
    background-color: white;
}

.motivation-container {
    display: flex;
    align-items: center;
    gap: 50px;
}

.motivation-content {
    flex: 1;
}

.motivation-content h2 {
    font-size: 2.2rem;
    color: var(--text-color);
    margin-bottom: 15px;
}

.motivation-content p {
    font-size: 1.2rem;
    color: #555;
}

.small-img {
    max-width: 200px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.motivation-image {
    flex: 1;
    text-align: center;
    background: #fff3e0;
    border-radius: 50%;
    padding: 30px;
}

.motivation-image img {
    max-width: 100%;
    max-height: 400px;
}

/* Contact Section */
.contact {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--primary-color) 0%, #004085 100%);
    color: white;
    text-align: center;
}

.contact-box h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: white;
}

.contact-box p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.contact-number {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 40px;
    letter-spacing: 1px;
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.number-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px 30px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.number-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.4);
}

.small-btn {
    font-size: 1rem;
    padding: 10px 20px;
    margin-top: 15px;
}

/* Footer */
footer {
    background-color: #222;
    color: #ccc;
    padding: 40px 0 20px;
    text-align: center;
}

.footer-logo img {
    height: 60px;
    filter: brightness(0) invert(1);
    margin-bottom: 15px;
}

.footer-logo p {
    font-size: 1.2rem;
    color: white;
    margin-bottom: 20px;
}

.footer-logo span {
    font-size: 0.9rem;
    color: var(--secondary-color);
    display: block;
}

.footer-bottom {
    border-top: 1px solid #444;
    padding-top: 20px;
    font-size: 0.9rem;
}

/* Responsive */
@media screen and (max-width: 992px) {
    .hero-container, .about-container, .motivation-container {
        flex-direction: column;
        text-align: center;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .features li {
        justify-content: center;
    }

    .class-item {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
}

@media screen and (max-width: 768px) {
    .nav-links {
        position: absolute;
        right: 0px;
        height: 90vh;
        top: 90px;
        background-color: var(--light-bg);
        display: none;
        flex-direction: column;
        align-items: center;
        width: 100%;
        box-shadow: 0 10px 10px rgba(0,0,0,0.1);
    }

    .nav-links.nav-active {
        display: flex;
        padding-top: 30px;
    }

    .burger {
        display: block;
    }
    
    .contact-number {
        font-size: 1.8rem;
    }
}

/* --- ANIMATIONS & EFFECTS --- */

/* Floating Images */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

.floating-img {
    animation: float 4s ease-in-out infinite;
}

.floating-img-slow {
    animation: float 6s ease-in-out infinite;
}

/* Pulsing Button */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.pulse-btn {
    animation: pulse 2s infinite;
}

.pulse-shape {
    animation: pulse 4s ease-in-out infinite;
}

/* Glow Text / Lightning */
@keyframes glow {
    0%, 100% { text-shadow: 0 0 10px rgba(0, 86, 179, 0.5), 0 0 20px rgba(0, 86, 179, 0.3); }
    50% { text-shadow: 0 0 20px rgba(0, 86, 179, 0.8), 0 0 30px rgba(0, 86, 179, 0.6), 0 0 40px rgba(0, 86, 179, 0.4); }
}

.glow-text span {
    animation: glow 2s ease-in-out infinite;
}

/* Lightning Background Effect */
@keyframes flash {
    0%, 95%, 98%, 100% { background: linear-gradient(135deg, #fdfbfb 0%, #ebedee 100%); }
    96%, 99% { background: linear-gradient(135deg, rgba(255,255,255,1) 0%, rgba(200,225,255,0.8) 100%); }
}

.lightning-bg {
    animation: flash 8s infinite;
}

/* Hover Glow for Icons */
.class-item:hover .glow-icon {
    box-shadow: 0 0 20px var(--primary-color);
    background-color: var(--primary-color);
    color: white;
    transition: all 0.4s ease;
}

.class-card {
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
}

.class-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}