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

header {
    background-color: #333;
    color: #fff;
    padding: 1.5rem 0;
    text-align: center;
    border-bottom: 5px solid #55aaff;
}

header h1 {
    margin: 0;
    font-size: 2.5rem;
}

main {
    padding: 20px;
    max-width: 1200px;
    margin: 20px auto;
}

section {
    background-color: #fff;
    margin-bottom: 30px;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

section h2 {
    color: #333;
    border-bottom: 2px solid #55aaff;
    padding-bottom: 10px;
    margin-top: 0;
    font-size: 2rem;
}

.course-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.course-card {
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}

.course-cover {
    width: 100%;
    max-height: 200px;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 10px;
    background-color: #eee; /* Placeholder color if image is missing */
}

.course-card h3 {
    font-size: 1.4rem;
    margin-top: 0;
    margin-bottom: 10px;
    color: #0056b3;
}

.course-card .price {
    font-weight: bold;
    color: #28a745;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.course-card .description {
    font-size: 0.95rem;
    margin-bottom: 15px;
    flex-grow: 1; /* Allows description to take available space */
    color: #555;
}

.course-link {
    display: inline-block;
    background-color: #007bff;
    color: white;
    padding: 10px 15px;
    text-decoration: none;
    border-radius: 5px;
    text-align: center;
    transition: background-color 0.3s ease;
    margin-top: auto; /* Pushes link to the bottom */
}

.course-link:hover {
    background-color: #0056b3;
}

footer {
    text-align: center;
    padding: 20px;
    background-color: #333;
    color: #fff;
    margin-top: 30px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    header h1 {
        font-size: 2rem;
    }
    section h2 {
        font-size: 1.8rem;
    }
    .course-grid {
        grid-template-columns: 1fr; /* Single column on smaller screens */
    }
    .course-card h3 {
        font-size: 1.2rem;
    }
}

