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

:root {
    /* 未来科技配色 */
    --primary-color: #00f5ff;
    --primary-light: #00d4ff;
    --primary-dark: #0099cc;
    --secondary-color: #ff6b9d;
    --accent-color: #a78bfa;
    --neon-cyan: #00f5ff;
    --neon-pink: #ff00ff;
    --neon-purple: #8b5cf6;
    
    /* 深色背景 */
    --background-color: #0a0e27;
    --background-gradient: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
    --card-background: rgba(255, 255, 255, 0.05);
    --card-background-hover: rgba(255, 255, 255, 0.08);
    
    /* 文字颜色 */
    --text-primary: #ffffff;
    --text-secondary: #e0e7ef;
    --text-light: #c0cdd8;
    
    /* 边框和阴影 */
    --border-color: rgba(0, 245, 255, 0.2);
    --border-glow: rgba(0, 245, 255, 0.5);
    --shadow-sm: 0 2px 8px rgba(0, 245, 255, 0.1);
    --shadow-md: 0 4px 16px rgba(0, 245, 255, 0.15);
    --shadow-lg: 0 8px 32px rgba(0, 245, 255, 0.2);
    --shadow-glow: 0 0 20px rgba(0, 245, 255, 0.3);
    
    /* 圆角和过渡 */
    --radius-sm: 12px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--background-gradient);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* 背景动态光效 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 30%, rgba(0, 245, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255, 0, 255, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(139, 92, 246, 0.05) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
    animation: backgroundPulse 8s ease-in-out infinite;
}

@keyframes backgroundPulse {
    0%, 100% {
        opacity: 0.6;
    }
    50% {
        opacity: 1;
    }
}

.app-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

.app-header {
    background: rgba(15, 12, 41, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 1.25rem 2rem;
    box-shadow: 0 4px 30px rgba(0, 245, 255, 0.1);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-icon {
    font-size: 2.5rem;
    filter: drop-shadow(0 0 10px rgba(0, 245, 255, 0.5));
    animation: logoFloat 3s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

.logo h1 {
    font-size: 1.75rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-pink), var(--neon-purple));
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 5s ease infinite;
    text-shadow: 0 0 30px rgba(0, 245, 255, 0.3);
}

@keyframes gradientShift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

.nav-menu {
    display: flex;
    gap: 0.75rem;
}

.nav-item {
    padding: 0.625rem 1.25rem;
    text-decoration: none;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: var(--transition);
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

.nav-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 245, 255, 0.1), rgba(255, 0, 255, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav-item:hover {
    color: var(--neon-cyan);
    text-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
}

.nav-item:hover::before {
    opacity: 1;
}

.nav-item.active {
    background: linear-gradient(135deg, rgba(0, 245, 255, 0.2), rgba(139, 92, 246, 0.2));
    color: var(--neon-cyan);
    border: 1px solid var(--border-glow);
    box-shadow: 0 0 20px rgba(0, 245, 255, 0.3), inset 0 0 20px rgba(0, 245, 255, 0.1);
    text-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
}

.nav-item.admin-link {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.3), rgba(236, 72, 153, 0.3));
    color: #f0abfc;
    border: 1px solid rgba(236, 72, 153, 0.3);
}

.nav-item.admin-link:hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.5), rgba(236, 72, 153, 0.5));
    color: #f9a8d4;
    text-shadow: 0 0 10px rgba(236, 72, 153, 0.5);
}

.nav-item.theory-link {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(59, 130, 246, 0.2));
    color: #86efac;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.nav-item.theory-link:hover {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.4), rgba(59, 130, 246, 0.4));
    color: #bbf7d0;
    text-shadow: 0 0 10px rgba(34, 197, 94, 0.5);
}

.main-content {
    flex: 1;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

.page {
    display: none;
}

.page.active {
    display: block;
    animation: fadeIn 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero {
    text-align: center;
    padding: 4rem 1rem;
    margin-bottom: 3rem;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 245, 255, 0.15) 0%, transparent 70%);
    pointer-events: none;
    animation: heroGlow 4s ease-in-out infinite;
}

@keyframes heroGlow {
    0%, 100% {
        opacity: 0.5;
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.1);
    }
}

.hero h2 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-pink), var(--neon-purple));
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 5s ease infinite;
    text-shadow: 0 0 40px rgba(0, 245, 255, 0.3);
    position: relative;
    z-index: 1;
}

.hero p {
    font-size: 1.375rem;
    color: var(--text-secondary);
    position: relative;
    z-index: 1;
}

.test-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.test-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: var(--transition);
    border: 1px solid rgba(0, 245, 255, 0.15);
    position: relative;
    overflow: hidden;
}

.test-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--neon-cyan), var(--neon-pink), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.test-card::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(0, 245, 255, 0.05) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.test-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 48px rgba(0, 245, 255, 0.25);
    border-color: rgba(0, 245, 255, 0.4);
    background: rgba(255, 255, 255, 0.05);
}

.test-card:hover::before {
    opacity: 1;
}

.test-card:hover::after {
    opacity: 1;
}

.test-card.coming-soon {
    opacity: 0.5;
    filter: grayscale(0.5);
}

.test-card.coming-soon:hover {
    transform: none;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.test-icon {
    font-size: 3.5rem;
    margin-bottom: 1.25rem;
    display: inline-block;
    filter: drop-shadow(0 0 15px rgba(0, 245, 255, 0.4));
    animation: iconPulse 3s ease-in-out infinite;
}

@keyframes iconPulse {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 0 15px rgba(0, 245, 255, 0.4));
    }
    50% {
        transform: scale(1.05);
        filter: drop-shadow(0 0 25px rgba(0, 245, 255, 0.6));
    }
}

.test-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
    text-shadow: 0 0 20px rgba(0, 245, 255, 0.2);
}

.test-card p {
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
    line-height: 1.7;
}

.test-info {
    display: flex;
    gap: 1.25rem;
    margin-bottom: 1.75rem;
    flex-wrap: wrap;
}

.info-item {
    font-size: 0.9rem;
    color: var(--text-light);
    padding: 0.375rem 0.875rem;
    background: rgba(0, 245, 255, 0.1);
    border-radius: 20px;
    border: 1px solid rgba(0, 245, 255, 0.2);
}

.btn-start {
    width: 100%;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, rgba(0, 245, 255, 0.2), rgba(139, 92, 246, 0.2));
    color: var(--neon-cyan);
    border: 1px solid var(--neon-cyan);
    border-radius: var(--radius-md);
    font-size: 1.0625rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    text-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
    box-shadow: 0 0 20px rgba(0, 245, 255, 0.2);
}

.btn-start::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-start:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 30px rgba(0, 245, 255, 0.5), 0 0 60px rgba(0, 245, 255, 0.3);
    background: linear-gradient(135deg, rgba(0, 245, 255, 0.3), rgba(139, 92, 246, 0.3));
    border-color: var(--neon-cyan);
}

.btn-start:hover::before {
    left: 100%;
}

.btn-start:active {
    transform: translateY(-1px);
}

.btn-start.disabled {
    background: rgba(122, 139, 163, 0.1);
    border-color: rgba(122, 139, 163, 0.3);
    color: var(--text-light);
    cursor: not-allowed;
    box-shadow: none;
    text-shadow: none;
}

.btn-start.disabled:hover {
    transform: none;
    box-shadow: none;
}

.page-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.page-header h2 {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-pink));
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 5s ease infinite;
}

.page-header p {
    color: var(--text-secondary);
    font-size: 1.125rem;
}

.test-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.test-item {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: var(--radius-md);
    padding: 1.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(0, 245, 255, 0.15);
    transition: var(--transition);
}

.test-item:hover {
    box-shadow: 0 8px 30px rgba(0, 245, 255, 0.2);
    border-color: rgba(0, 245, 255, 0.3);
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(5px);
}

.test-item-left {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.test-icon-small {
    font-size: 2.5rem;
    filter: drop-shadow(0 0 10px rgba(0, 245, 255, 0.4));
}

.test-item-info h4 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.375rem;
    color: var(--text-primary);
}

.test-item-info p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.test-item-right {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.duration {
    color: var(--text-light);
    font-size: 0.9375rem;
    padding: 0.375rem 0.875rem;
    background: rgba(0, 245, 255, 0.1);
    border-radius: 20px;
    border: 1px solid rgba(0, 245, 255, 0.2);
}

.btn-start-small {
    padding: 0.625rem 1.5rem;
    background: linear-gradient(135deg, rgba(0, 245, 255, 0.2), rgba(139, 92, 246, 0.2));
    color: var(--neon-cyan);
    border: 1px solid var(--neon-cyan);
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
    box-shadow: 0 0 15px rgba(0, 245, 255, 0.2);
}

.btn-start-small:hover {
    background: linear-gradient(135deg, rgba(0, 245, 255, 0.3), rgba(139, 92, 246, 0.3));
    box-shadow: 0 0 25px rgba(0, 245, 255, 0.4);
    transform: translateY(-2px);
}

.results-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.empty-state {
    text-align: center;
    padding: 5rem 2rem;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(0, 245, 255, 0.15);
}

.empty-icon {
    font-size: 5rem;
    display: block;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 20px rgba(0, 245, 255, 0.4));
    animation: iconFloat 3s ease-in-out infinite;
}

@keyframes iconFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.empty-state p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 1.125rem;
}

.btn-primary {
    padding: 0.875rem 2.5rem;
    background: linear-gradient(135deg, rgba(0, 245, 255, 0.2), rgba(139, 92, 246, 0.2));
    color: var(--neon-cyan);
    border: 1px solid var(--neon-cyan);
    border-radius: var(--radius-md);
    font-size: 1.0625rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
    box-shadow: 0 0 20px rgba(0, 245, 255, 0.2);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 30px rgba(0, 245, 255, 0.5), 0 0 60px rgba(0, 245, 255, 0.3);
    background: linear-gradient(135deg, rgba(0, 245, 255, 0.3), rgba(139, 92, 246, 0.3));
}

.btn-secondary {
    padding: 0.875rem 2.5rem;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    border: 1px solid rgba(0, 245, 255, 0.3);
    border-radius: var(--radius-md);
    font-size: 1.0625rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--neon-cyan);
    border-color: var(--neon-cyan);
    box-shadow: 0 0 20px rgba(0, 245, 255, 0.2);
}

.app-footer {
    background: rgba(15, 12, 41, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 2rem;
    text-align: center;
    border-top: 1px solid rgba(0, 245, 255, 0.15);
    margin-top: auto;
}

.app-footer p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.app-footer .disclaimer {
    color: var(--text-light);
    font-size: 0.8125rem;
    margin-top: 0.75rem;
    opacity: 0.7;
}

/* 用户状态样式 */
.user-status {
    display: flex;
    align-items: center;
    gap: 12px;
}

.login-link {
    color: #00f5ff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    padding: 10px 20px;
    border: 2px solid #00f5ff;
    border-radius: 10px;
    transition: all 0.3s ease;
    background: rgba(0, 245, 255, 0.1);
    text-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
}

.login-link:hover {
    background: rgba(0, 245, 255, 0.2);
    border-color: #00f5ff;
    box-shadow: 0 0 20px rgba(0, 245, 255, 0.5), 0 0 40px rgba(0, 245, 255, 0.3);
    transform: translateY(-2px);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-name {
    color: #ffffff;
    font-size: 14px;
    font-weight: 500;
}

.logout-btn {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.4);
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.logout-btn:hover {
    background: rgba(239, 68, 68, 0.3);
    border-color: rgba(239, 68, 68, 0.6);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.3);
}

.admin-link {
    color: #fbbf24;
    text-decoration: none;
    font-size: 16px;
    margin-left: 8px;
    transition: all 0.3s ease;
    display: inline-block;
}

.admin-link:hover {
    color: #f59e0b;
    transform: rotate(90deg);
    text-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
}

.hidden {
    display: none !important;
}

@media (max-width: 768px) {
    .app-header {
        flex-direction: column;
        gap: 1.25rem;
        padding: 1rem;
    }
    
    .nav-menu {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .nav-item {
        padding: 0.5rem 1rem;
        font-size: 0.9375rem;
    }
    
    .main-content {
        padding: 1.5rem 1rem;
    }
    
    .hero {
        padding: 2.5rem 1rem;
    }
    
    .hero h2 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1.125rem;
    }
    
    .test-cards {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .test-card {
        padding: 2rem;
    }
    
    .test-item {
        flex-direction: column;
        gap: 1.25rem;
        text-align: center;
        padding: 1.5rem;
    }
    
    .test-item-left {
        flex-direction: column;
    }
    
    .test-item-right {
        width: 100%;
        justify-content: center;
        flex-direction: column;
        gap: 1rem;
    }
    
    .duration {
        font-size: 0.875rem;
    }
}
