.test-container {
    max-width: 1400px;
    margin: 0 auto;
    padding-bottom: 40px;
}

.page-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 25px;
    box-shadow: 0 10px 40px rgba(102, 126, 234, 0.3);
    color: white;
}

.header-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    flex-shrink: 0;
}

.header-text {
    flex: 1;
}

.header-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 10px;
}

.header-subtitle {
    font-size: 1.2rem;
    margin: 0;
    opacity: 0.9;
}

.test-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.test-section {
    display: flex;
}

.section-card,
.tips-card {
    background: white;
    border-radius: 18px;
    padding: 30px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
}

.section-card {
    flex: 1;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.section-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2d3748;
    margin: 0;
}

.section-desc {
    font-size: 1rem;
    color: #718096;
    margin-bottom: 25px;
}

.grade-options,
.test-types {
    display: flex;
    flex-direction: column;
}

.grade-options {
    gap: 12px;
}

.test-types {
    gap: 12px;
}

.grade-option {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 18px 20px;
    background: #f7fafc;
    border: 2px solid transparent;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    width: 100%;
}

.grade-option:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    border-color: rgba(102, 126, 234, 0.3);
    transform: translateX(5px);
}

.grade-option.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: transparent;
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
}

.grade-option.active .grade-option-icon,
.grade-option.active .grade-option-text {
    color: white;
}

.grade-option-icon {
    width: 45px;
    height: 45px;
    background: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #667eea;
    flex-shrink: 0;
}

.grade-option.active .grade-option-icon {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.grade-option-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
}

.test-type-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 18px 20px;
    background: #f7fafc;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.test-type-card:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    border-color: rgba(102, 126, 234, 0.2);
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.1);
}

.test-type-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    flex-shrink: 0;
}

.test-type-icon-1 {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
}

.test-type-icon-2 {
    background: linear-gradient(135deg, #4299e1 0%, #3182ce 100%);
}

.test-type-icon-3 {
    background: linear-gradient(135deg, #9f7aea 0%, #805ad5 100%);
}

.test-type-icon-4 {
    background: linear-gradient(135deg, #f6ad55 0%, #ed8936 100%);
}

.test-type-icon-5 {
    background: linear-gradient(135deg, #fc8181 0%, #f56565 100%);
}

.test-type-content {
    flex: 1;
}

.test-type-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
    margin: 0 0 5px;
}

.test-type-desc {
    font-size: 0.9rem;
    color: #718096;
    margin: 0;
    line-height: 1.5;
}

.test-type-arrow {
    font-size: 1.2rem;
    color: #cbd5e0;
    transition: all 0.3s ease;
}

.test-type-card:hover .test-type-arrow {
    color: #667eea;
    transform: translateX(3px);
}

.grade-prompt {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 40px 20px;
    color: #718096;
    font-size: 1rem;
    text-align: center;
}

.grade-prompt i {
    font-size: 1.2rem;
}

.racing-game-card {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border-radius: 18px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 10px 40px rgba(240, 147, 251, 0.3);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.racing-game-header {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
}

.racing-icon {
    font-size: 4rem;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.racing-text h3 {
    color: white;
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0 0 8px;
}

.racing-text p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    margin: 0;
}

.btn-racing {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 35px;
    background: white;
    color: #f5576c;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-racing:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    color: #f5576c;
}

.tips-header {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.3rem;
    font-weight: 600;
    color: #667eea;
    margin-bottom: 20px;
}

.tips-header i {
    font-size: 1.5rem;
}

.tips-list {
    list-style: none;
    padding: 0;
    margin: 0 0 25px;
}

.tips-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    font-size: 1.05rem;
    color: #4a5568;
    line-height: 1.6;
}

.tips-list li i {
    color: #48bb78;
    font-size: 1.2rem;
    flex-shrink: 0;
    margin-top: 3px;
}

.tips-action {
    text-align: center;
}

.btn-history {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-history:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    color: white;
}

@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        text-align: center;
        padding: 30px 20px;
    }

    .header-title {
        font-size: 2rem;
    }

    .test-grid {
        grid-template-columns: 1fr;
    }

    .racing-game-card {
        flex-direction: column;
        text-align: center;
    }

    .racing-game-header {
        flex-direction: column;
    }

    .racing-text h3 {
        font-size: 1.5rem;
    }

    .racing-text p {
        font-size: 1rem;
    }
}
