/* General Reset and Basic Styling */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    color: #333;
    line-height: 1.6;
}

/* Header */
header {
    background-color: rgb(0, 120, 215);
    color: rgb(223, 221, 217);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

header nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

header nav ul li a {
    text-decoration: none;
    color: rgb(255, 153, 0);
    font-weight: bold;
}

/* Sections */
#education {
    min-height: 500px;
    width: 100%;
    padding: 2rem;
}

.foot, #foot {
    min-height: 300px;
    width: 100%;
}

#img5 {
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* Banners */
#b1, #b2 {
    background-size: cover;
    background-position: center;
    height: 60vh;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

#b1 {
    background: url('banner1.jpg') no-repeat center center;
}

#b2 {
    background: url('banner3.jpg') no-repeat center center;
    color: white;
}

/* Hero */
.hero {
    background: url('hero-image.jpg') no-repeat center center/cover;
    min-height: 50vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
    padding: 1rem;
}

.hero h2 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
}

.hero .btn {
    padding: 10px 20px;
    background-color: #0066cc;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    display: inline-block;
    margin-top: 1rem;
}

/* Courses */
section {
    padding: 2rem;
    background-color: white;
}

#courses .courses-container {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.course-card {
    background-color: #fafafa;
    flex: 1 1 280px;
    max-width: 320px;
    padding: 1rem;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    text-align: center;
}

.course-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 5px;
}

.course-card h3 {
    font-size: 1.2rem;
    margin: 1rem 0;
}

/* Footer */
footer {
    background-color: #333;
    color: white;
    padding: 1rem;
    text-align: center;
}

/* Responsive */
@media (max-width: 1024px) {
    header {
        flex-direction: column;
        text-align: center;
    }

    header nav ul {
        justify-content: center;
    }

    #b1, #b2, .hero {
        height: 50vh;
    }
}

@media (max-width: 768px) {
    header nav ul {
        flex-direction: column;
        gap: 1rem;
    }

    .courses-container {
        flex-direction: column;
        align-items: center;
    }

    .course-card {
        width: 90%;
    }
}

@media (max-width: 480px) {
    .hero h2 {
        font-size: 1.5rem;
    }

    .hero .btn {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
}
/* Scrolling/Carousel Image Optimization */
.slider img,
.carousel img {
  width: 100%;       /* take full container width */
  height: auto;      /* keep aspect ratio */
  max-height: 400px; /* optional: limit height */
  object-fit: cover; /* crop nicely without distortion */
  border-radius: 10px; /* smooth corners */
}

/* For smaller devices */
@media (max-width: 768px) {
  .slider img,
  .carousel img {
    max-height: 250px; 
  }
}

@media (max-width: 480px) {
  .slider img,
  .carousel img {
    max-height: 180px; 
  }
}
