* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #007bff;
    --secondary-color: #0056b3;
    --dark-color: #343a40;
    --light-color: #f8f9fa;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --border-radius: 5px;
    --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.header {
    padding: 20px 0;
    background-color: #fff;
    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;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo i {
    color: #007bff;
    font-size: 30px;
    font-weight: 700;
}

.logo h1 {
    color: #007bff;
    font-size: 30px;
    font-weight: 700;
}
.btn-login {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 25px;
    border-radius: 50px;
    background: linear-gradient(135deg, #007bff, #00c6ff);
    color: #fff;
    font-weight: 500;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-login:hover {
    background: linear-gradient(135deg, #0056b3, #0099cc);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}

.btn-login i {
    font-size: 16px;
}

.user-menu {
  position: relative;
}

.dropdown-btn {
  background: linear-gradient(135deg, #007bff, #00c6ff);
  color: white;
  border: none;
  padding: 10px 25px;
  border-radius: 50px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
}

.dropdown-btn:hover {
  background: linear-gradient(135deg, #0056b3, #0099cc);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}

.dropdown-content {
  position: absolute;
  top: 45px;
  right: 0;
  background-color: white;
  min-width: 140px;
  border: 1px solid #ddd;
  border-radius: 5px;
  box-shadow: 0px 4px 8px rgba(0,0,0,0.1);
  display: none;
  z-index: 2000;
}

.dropdown-content a {
  display: block;
  padding: 8px 12px;
  color: #333;
  text-decoration: none;
}

.dropdown-content a:hover {
  background-color: #f0f0f0;
}

.user-menu:hover .dropdown-content {
  display: none;
}

#dropdownContent.show {
    display: block;
}

.btn {
    display: inline-block;
    background-color: #007bff;
    color: #fff;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn {
    display: inline-block;
    background-color: #007bff;
    color: #fff;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn-small {
    display: inline-block;
    background-color: #007bff;
    color: #fff;
    padding: 8px 20px;
    border-radius: 50px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-small:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
}

.main-nav ul {
    display: flex;
    list-style: none;
}

.main-nav li {
    margin-left: 30px;
}

.main-nav a {
    text-decoration: none;
    color: #343a40;
    font-weight: 500;
    padding: 5px 0;
    position: relative;
    transition: color 0.3s;
}

.main-nav a:hover,
.main-nav .active a {
    color:#007bff;
}

.main-nav a:after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color:#007bff;
    transition: width 0.3s;
}

.main-nav a:hover:after,
.main-nav .active a:after {
    width: 100%;
}

.stats-row {
    display: flex;
    gap: 40px;
    margin-top: 20px;
}

.stat-item h2 {
    font-size: 32px;
    color: #007bff;
}

.stat-item p {
    font-size: 14px;
    color: #007bff;
}

.hero {
    padding: 80px 0;
    background: linear-gradient(135deg, #fff 0%, #e4e8f0 100%);
}

.hero .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}

.hero-content {
    flex: 1;
    min-width: 300px;
    padding-right: 30px;
    animation: fadeInUp 1s ease forwards;
}

.hero-content h1 {
    font-size: 48px;
    margin-bottom: 20px;
    color: #343a40;
    line-height: 1.2;
}

.hero-content h1 span {
    color: #007bff;
}

.hero-content p {
    font-size: 18px;
    color: #555;
    margin-bottom: 30px;
    max-width: 500px;
}

.hero-image {
    flex: 1;
    min-width: 300px;
    text-align: center;
    animation: fadeInUp 1s ease forwards;
}

.hero-image img {
    max-width: 100%;
    height: 350px;
    border-radius: 10px;
}

.categories {
    padding: 80px 0;
    background-color: #fff;
}

.categories h2 {
    text-align: center;
    margin-bottom: 50px;
    font-size: 36px;
    color: #343a40;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.category-card {
    background: #fff;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    animation: appear 5s linear;
    animation-timeline: view();
    animation-range: entry 0% cover 40%;
}

.category-card:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.category-card i {
    font-size: 48px;
    color: #007bff;
    margin-bottom: 20px;
}

.category-card h3 {
    font-size: 24px;
    margin-bottom: 15px;
    color: #343a40;
}

.category-card p {
    color: #666;
    margin-bottom: 20px;
}

.featured-quizzes {
    padding: 80px 0;
    background-color: #f8f9fa;
}

.featured-quizzes h2 {
    text-align: center;
    margin-bottom: 50px;
    font-size: 36px;
    color: #343a40;
}

.quiz-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.quiz-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    animation: appear 5s linear;
    animation-timeline: view();
    animation-range: entry 0% cover 40%;
}

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

.quiz-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.quiz-info {
    padding: 20px;
}

.quiz-info h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: #343a40;
}

.quiz-info p {
    color: #666;
    margin-bottom: 15px;
}

.quiz-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    color: #777;
    font-size: 14px;
}

.quiz-meta i {
    margin-right: 5px;
    color: #007bff;
}

.footer {
    background-color: #343a40;
    color: #fff;
    padding: 60px 0 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.footer-section h3 {
    font-size: 20px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-section h3:after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 2px;
    background-color: #343a40;
}

.footer-section p {
    margin-bottom: 15px;
    color: #bbb;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: #bbb;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #007bff;
}

.footer-bottom {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 14px;
    color: #bbb;
}

/* ===== Animations ===== */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

@keyframes appear {
    from {
        opacity: 0;
        transform: scale(0.4);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

