/* General Styles */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

/* Header */
header {
    background-color: #aa0017;
    color: white;
    text-align: center;
    padding: 10px 15px;
    font-size: 18px;
}

/* Main Container */
.container {
    display: flex;
    margin: 20px;
    gap: 20px;
}

/* Sidebar */
.sidebar {
    flex: 0 0 25%; /* Fixed width of 25% for larger screens */
    max-width: 300px;
    padding: 20px;
    background-color: #f8f8f8;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.sidebar h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.sidebar select {
    width: 100%;
    padding: 10px;
    margin-bottom: 20px;
    border: 1px solid #ccc;
    border-radius: 5px;
}

.reset-btn {
    width: 100%;
    padding: 10px;
    background: #4CAF50;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 10px;
    font-size: 16px;
}

.reset-btn:hover {
    background: #d32f2f;
}

/* Main Content */
.main-content {
    flex: 1; /* Takes remaining width for larger screens */
    padding: 20px;
}

/* College Grid */
.college-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* Flexible layout */
    gap: 20px;
}

.college-card {
    border: 1px solid #ddd;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    background: #fff;
    transition: transform 0.3s ease;
}

.college-card:hover {
    transform: translateY(-5px);
}

.college-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.college-info {
    padding: 15px;
}

.college-info h2 {
    margin: 0 0 10px;
    font-size: 1.2rem;
    color: #333;
}

.college-info p {
    margin: 5px 0;
    font-size: 0.9rem;
    color: #555;
}

.college-info .btn {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 15px;
    background: #aa0017;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    text-align: center;
}

.college-info .btn:hover {
    background: #45a049;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    gap: 10px;
}

.pagination a {
    padding: 10px 15px;
    text-decoration: none;
    background-color: #4CAF50;
    color: white;
    border-radius: 5px;
    font-size: 16px;
}

.pagination a:hover {
    background-color: #45a049;
}

.pagination .active {
    background-color: #333;
}

/* Footer */
footer {
    text-align: center;
    padding: 12px;
    background-color: #aa0017;
    color: white;
    position: relative;
    width: 100%;
}

footer p {
    margin: 0;
    font-size: 16px;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .container {
        flex-direction: column; /* Stacks sidebar and main content */
    }

    .sidebar {
        flex: 1;
        max-width: 100%; /* Full width for smaller screens */
    }

    .main-content {
        flex: 1;
    }

    .college-grid {
        grid-template-columns: 1fr; /* Single column layout for small screens */
    }
}
