body {
    font-family: 'Inter', sans-serif;
    background-color: #f8f9fa; /* Lighter background */
}
.quiz-card {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out, opacity 0.3s ease-in-out; /* Added opacity transition */
     /* Remove default card border border: none; */
    border-radius: 0.75rem; /* More rounded corners */
    background-color: #ffffff; /* White card background */
    height: 100%; /* Ensure cards have same height for alignment */
}
.quiz-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1); /* Enhanced shadow on hover */
}
.quiz-card-title {
    font-size: 1.2rem;
    font-weight: 600; /* Slightly bolder title */
    color: #343a40; /* Darker title color */
    margin-bottom: 0.75rem;
}
.quiz-card-description {
    color: #6c757d; /* Standard muted text color */
    font-size: 0.85rem;
    margin-bottom: .8rem;
    flex-grow: 1; /* Allow description to take up space */
    margin-top: 0.3rem; /* Space above description */
}
.quiz-card-meta { /* Style for question count */
    font-size: 0.85rem;
    color: #6c757d; /* Muted color */
}
.quiz-card-link {
    color: #0d6efd; /* Bootstrap primary blue */
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease;
    font-size: 1rem;
    margin-top: auto; /* Push link to bottom */
}
.quiz-card-link:hover {
    color: #0a58ca; /* Darker blue on hover */
}

/* .navbar-brand {
    font-family: 'Inter', sans-serif;
    font-size: 1.8rem;
    font-weight: 700; /* Bolder brand 
    color: #343a40;
}
.navbar-brand:hover {
    color: #212529;
} */
.bg-white {
    background-color: #ffffff !important; /* Ensure navbar is white */
}
.bd-gutter {
    background-color: #9461fb !important; /* Ensure navbar is white */
}
.header-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); /* Gradient background */
    color: #ffffff; /* White text on gradient */
}
.header-bg h1 {
    color: #ffffff;
}
.header-bg p {
    color: rgba(255, 255, 255, 0.8); /* Slightly transparent white */
}
.filter-controls {
    margin-bottom: 0px; /* Increased margin below controls */
}
.search-input {
    max-width: 400px; /* Limit search bar width */
    margin: 0 auto 1.5rem; /* Center search bar */
}
.filter-btn {
    margin: 0 5px 10px; /* Spacing around filter buttons */
    border-radius: 20px; /* Pill-shaped buttons */
    font-weight: 500;
    transition: background-color 0.2s ease, color 0.2s ease;
}
.filter-btn.active {
    background-color: #0d6efd !important; /* Use Bootstrap primary color for active */
    color: white !important;
    border-color: #0d6efd !important;
}
.quiz-tags span {
    background-color: #e9ecef; /* Light gray background for tags */
    color: #495057; /* Darker text for tags */
    padding: 0.25rem 0.6rem;
    border-radius: 0.25rem;
    font-size: 0.8rem;
    margin-right: 5px;
    margin-bottom: 5px;
    display: inline-block;
}
.quiz-card .card-body {
    display: flex;
    flex-direction: column;
    height: 100%; /* Ensure card body takes full height */
}
.quiz-item {
    /* Styles for smooth transition */
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}
.quiz-item.hidden {
   opacity: 0;
   transform: scale(0.95);
   /* We use JS to set display: none after transition */
   pointer-events: none; /* Prevent interaction while hidden */
   height: 0; /* Collapse space */
   overflow: hidden; /* Hide content */
   padding-top: 0; /* Collapse padding */
   padding-bottom: 0;
   margin-top: 0; /* Collapse margin */
   margin-bottom: 0;
}

/* Style for pagination */
.pagination-container {
    margin-top: 2rem; /* Space above pagination */
}
.pagination .page-link {
    transition: background-color 0.2s ease, color 0.2s ease;
}
.pagination .page-item.active .page-link {
    background-color: #0d6efd;
    border-color: #0d6efd;
}
 .pagination .page-item.disabled .page-link {
    color: #6c757d;
    pointer-events: none;
    background-color: #fff;
    border-color: #dee2e6;
}

/* Styling for the topic links (replacing list-group) */
.topic-link-item {
    display: block; /* Make the link fill the column */
    background-color: #ffffff;
    padding: 1rem 1.25rem;
    border-radius: 0.5rem;
    border: 1px solid #dee2e6;
    text-decoration: none;
    color: #495057;
    font-weight: 500;
    transition: background-color 0.2s ease-in-out, transform 0.2s ease-in-out, color 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    margin-bottom: 1rem; /* Spacing between items */
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.topic-link-item:hover {
    background-color: #e9ecef;
    transform: translateY(-3px);
    color: #0d6efd;
    box-shadow: 0 4px 8px rgba(0,0,0,0.08);
}

.topic-link-item i.topic-icon {
    margin-right: 0.75rem;
    color: #6c757d;
    transition: color 0.2s ease-in-out; /* Add transition for icon color */
}

.topic-link-item:hover i.topic-icon {
    color: #0d6efd; /* Change icon color on hover */
}

.topic-link-item .bi-chevron-right { /* Style the chevron */
     color: #adb5bd; /* Muted color */
     transition: color 0.2s ease-in-out;
}
.topic-link-item:hover .bi-chevron-right {
    color: #0d6efd; /* Change chevron color on hover */
}