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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.nav-brand {
    font-size: 1.5em;
    font-weight: bold;
    background: linear-gradient(45deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 20px;
}

.nav-menu a {
    text-decoration: none;
    color: #555;
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.nav-menu a:hover, .nav-menu a.active {
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.hamburger {
    display: none;
    background: none;
    border: none;
    font-size: 1.5em;
    cursor: pointer;
}

.hero {
    padding: 120px 20px 60px;
    text-align: center;
    color: white;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 2.5em;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.hero p {
    font-size: 1.2em;
    margin-bottom: 30px;
    opacity: 0.9;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    padding: 40px 0;
}

.feature-card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.feature-card .icon {
    font-size: 3em;
    margin-bottom: 15px;
}

.feature-card h3 {
    margin-bottom: 10px;
    color: #444;
}

.feature-card p {
    color: #777;
    line-height: 1.6;
}

.btn-primary {
    display: inline-block;
    padding: 12px 30px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.6);
}

.btn-secondary {
    display: inline-block;
    padding: 12px 30px;
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    border-radius: 25px;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn-secondary:hover {
    background: #667eea;
    color: white;
    transform: translateY(-3px);
}

footer {
    background: rgba(255, 255, 255, 0.95);
    text-align: center;
    padding: 20px;
    margin-top: 40px;
}

.footer-content a {
    color: #667eea;
    text-decoration: none;
}

.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.login-form {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 400px;
}

.login-form h2 {
    text-align: center;
    margin-bottom: 30px;
    color: #444;
}

.login-form input {
    width: 100%;
    padding: 12px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-size: 1em;
}

.login-form button {
    width: 100%;
}

.error {
    color: #e74c3c;
    text-align: center;
    margin-bottom: 20px;
}

.success {
    color: #2ecc71;
    text-align: center;
    margin-bottom: 20px;
}

.exam-header {
    background: white;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.exam-controls {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 20px;
}

.timer {
    font-size: 2em;
    font-weight: bold;
    color: #667eea;
    font-family: monospace;
}

.category-nav {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.category-nav button {
    padding: 8px 16px;
    border: 2px solid #667eea;
    background: white;
    color: #667eea;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-nav button:hover {
    background: #667eea;
    color: white;
}

.question-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.question-card h3 {
    color: #667eea;
    margin-bottom: 15px;
}

.question-card .options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.question-card .options label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid #eee;
    cursor: pointer;
    transition: all 0.3s ease;
}

.question-card .options label:hover {
    background: #f0f4ff;
    border-color: #667eea;
}

#result {
    background: white;
    border-radius: 20px;
    padding: 30px;
    margin-top: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

#historyChart {
    background: white;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    min-height: 300px;
}

#historyList {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

#reviewContent {
    display: grid;
    gap: 20px;
}

.review-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.review-card .wrong {
    color: #e74c3c;
}

.review-card .correct {
    color: #2ecc71;
}

#parentReport {
    background: white;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
    .hamburger {
        display: block;
    }
    
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .hero h1 {
        font-size: 1.8em;
    }
    
    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .exam-controls {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.5em;
    }
    
    .container {
        padding: 10px;
    }
}