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

html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

body {
    font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-size: 16px;
    position: relative;
    overflow-x: hidden;
}

p, span, div, label, button, input, textarea, h1, h2, h3, h4 {
    font-family: inherit;
}

.container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

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

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

.logo-icon {
    font-size: 1.5rem;
}

.logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: #667eea;
}

.nav {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.nav-link {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    text-decoration: none;
    color: #666;
    font-weight: 500;
    transition: all 0.3s;
    font-size: 0.95rem;
    white-space: nowrap;
}

.nav-link:hover {
    color: #667eea;
}

.nav-link.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.section {
    display: none;
    padding: 3rem 0;
    min-height: calc(100vh - 80px);
}

.section.active {
    display: block;
}

.hero-content {
    text-align: center;
    color: white;
    padding: 3rem 0;
}

.hero-content h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-content .btn-primary {
    background: white;
    color: #667eea;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.hero-content .btn-primary:hover {
    background: white;
    color: #764ba2;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.student-info-box {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 16px;
    padding: 1.5rem 2rem;
    margin-bottom: 2.5rem;
    backdrop-filter: blur(8px);
}

.student-info-row {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.info-group {
    flex: 1;
    text-align: left;
}

.info-group label {
    display: block;
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
    color: rgba(255, 255, 255, 0.9);
}

.info-group input {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1rem;
    transition: all 0.3s;
}

.info-group input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.info-group input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.5);
}

.student-info-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 0.5rem;
}

.student-info-buttons .btn-secondary {
    background: rgba(255, 255, 255, 0.35);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.8);
    font-weight: 600;
}

.student-info-buttons .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.5);
    border-color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.student-info-hint {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

.step-indicator {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin: 3rem 0;
}

.step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.step-num {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
}

.step-item.completed .step-num {
    background: white;
    color: #667eea;
}

.step-name {
    font-size: 0.9rem;
    font-weight: 500;
}

.step-line {
    width: 80px;
    height: 2px;
    background: rgba(255, 255, 255, 0.3);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

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

.btn-secondary {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    padding: 0.6rem 1.5rem;
    border-radius: 20px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
    color: white;
}

.section-header h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.section-header p {
    opacity: 0.9;
}

.topic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.topic-card {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.topic-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.topic-card.selected {
    border: 3px solid #667eea;
}

.topic-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.topic-card h3 {
    margin-bottom: 0.5rem;
    color: #333;
}

.topic-card p {
    color: #666;
    font-size: 0.9rem;
}

.custom-topic {
    display: flex;
    justify-content: center;
    gap: 1rem;
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    max-width: 600px;
    margin: 0 auto;
}

.custom-topic input {
    flex: 1;
    padding: 0.8rem 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
}

.custom-topic input:focus {
    outline: none;
    border-color: #667eea;
}

.custom-topic .btn-secondary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
}

.custom-topic .btn-secondary:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.plan-container {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #333;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
}

.device-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.tag {
    background: #f0f0f0;
    padding: 0.4rem 1rem;
    border-radius: 15px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s;
}

.tag:hover {
    background: #667eea;
    color: white;
}

.tag.selected {
    background: #667eea;
    color: white;
}

.architecture-diagram {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
}

.arch-box {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 3rem;
    border-radius: 10px;
    font-weight: 600;
    position: relative;
}

.arch-box::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 15px solid #764ba2;
}

.arch-layer:last-child .arch-box::after {
    display: none;
}

.next-btn,
.complete-btn {
    width: 100%;
    margin-top: 1rem;
}

.implement-container {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.08);
}

.evaluation-card {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.08);
}

.evaluation-locked {
    text-align: center;
    padding: 3rem 1rem;
    color: #999;
}

.lock-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.5;
}

.evaluation-locked h3 {
    color: #666;
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.evaluation-locked p {
    font-size: 0.9rem;
    line-height: 1.6;
}

.self-evaluation h4 {
    color: #555;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.eval-hint {
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 1.5rem;
}

.self-eval-item {
    margin-bottom: 1.2rem;
}

.self-eval-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: #555;
}

.self-eval-value {
    display: inline-block;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 2px 10px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.85rem;
    min-width: 32px;
    text-align: center;
}

.self-eval-slider {
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: linear-gradient(to right, #e0e0e0, #667eea);
    border-radius: 3px;
    outline: none;
    cursor: pointer;
}

.self-eval-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: white;
    border: 3px solid #667eea;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(102, 126, 234, 0.3);
    transition: transform 0.2s;
}

.self-eval-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

.self-eval-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: white;
    border: 3px solid #667eea;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(102, 126, 234, 0.3);
}

.eval-submit-btn {
    width: 100%;
    margin-top: 1rem;
}

.implement-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid #e0e0e0;
}

.tab-btn {
    padding: 0.8rem 1.5rem;
    border: none;
    background: none;
    font-weight: 500;
    cursor: pointer;
    color: #666;
    position: relative;
    transition: all 0.3s;
}

.tab-btn:hover {
    color: #667eea;
}

.tab-btn.active {
    color: #667eea;
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.language-select,
.comm-options {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.language-option,
.comm-option {
    padding: 0.8rem 1.5rem;
    background: #f0f0f0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
}

.language-option:hover,
.comm-option:hover {
    background: #667eea;
    color: white;
}

.language-option.selected,
.comm-option.selected {
    background: #667eea;
    color: white;
}

.canvas-placeholder {
    background: #f9f9f9;
    border: 2px dashed #e0e0e0;
    border-radius: 10px;
    padding: 3rem;
    text-align: center;
    color: #999;
}

.canvas-placeholder span {
    font-size: 3rem;
    display: block;
    margin-bottom: 0.5rem;
}

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

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

.test-item input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.test-item label {
    cursor: pointer;
}

/* AI助手圆形图标（固定在右下角） */
.ai-assistant-icon {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: white;
    border: 3px solid #764ba2;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
    z-index: 1000;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    overflow: hidden;
}

.ai-icon-emoji {
    font-size: 2rem;
    line-height: 1;
    display: block;
}

.ai-assistant-icon:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 32px rgba(102, 126, 234, 0.5);
}

.ai-icon-notification {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 20px;
    height: 20px;
    background: #ff4757;
    border-radius: 50%;
    border: 2px solid white;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(255, 71, 87, 0.7);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(255, 71, 87, 0);
    }
}

/* AI对话助手（固定在右下角） */
.ai-chat-assistant {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 380px;
    height: 560px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(102, 126, 234, 0.3);
    z-index: 1000;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: slideUp 0.3s ease;
}

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

.ai-chat-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.85rem 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    user-select: none;
    flex-shrink: 0;
}

.ai-chat-icon {
    font-size: 1.4rem;
    line-height: 1;
}

.ai-chat-title {
    flex: 1;
    font-weight: 600;
    font-size: 0.95rem;
}

.ai-chat-controls {
    display: flex;
    gap: 0.25rem;
}

.ai-chat-btn {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.4rem;
    cursor: pointer;
    padding: 0.1rem 0.5rem;
    border-radius: 4px;
    transition: background 0.2s ease;
    line-height: 1;
}

.ai-chat-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.ai-chat-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.ai-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ai-chat-message {
    display: flex;
    max-width: 85%;
    animation: fadeIn 0.3s ease;
}

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

.ai-chat-message-bot {
    align-self: flex-start;
}

.ai-chat-message-user {
    align-self: flex-end;
}

.ai-chat-bubble {
    padding: 0.65rem 0.9rem;
    border-radius: 12px;
    font-size: 0.85rem;
    line-height: 1.5;
    word-wrap: break-word;
}

.ai-chat-message-bot .ai-chat-bubble {
    background: rgba(102, 126, 234, 0.08);
    color: #333;
    border-bottom-left-radius: 4px;
}

.ai-chat-message-user .ai-chat-bubble {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-bottom-right-radius: 4px;
}

.ai-chat-input-box {
    padding: 0.75rem;
    border-top: 1px solid rgba(102, 126, 234, 0.1);
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.ai-chat-input-box input {
    flex: 1;
    padding: 0.65rem 0.9rem;
    border: 1.5px solid rgba(102, 126, 234, 0.2);
    border-radius: 10px;
    font-size: 0.85rem;
    outline: none;
    transition: border-color 0.2s ease;
}

.ai-chat-input-box input:focus {
    border-color: #667eea;
}

.ai-chat-send {
    padding: 0.65rem 1.2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    flex-shrink: 0;
}

.ai-chat-send:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.ai-chat-send:active {
    transform: translateY(0);
}

/* 证书样式 */
.certificate {
    background: linear-gradient(135deg, #faf7ff 0%, #f5f0ff 100%);
    border: 3px solid transparent;
    border-image: linear-gradient(135deg, #667eea, #764ba2);
    border-image-slice: 1;
    border-radius: 12px;
    padding: 1.5rem;
    position: relative;
    animation: fadeIn 0.5s ease;
}

.cert-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 2px dashed rgba(102, 126, 234, 0.3);
    margin-bottom: 1rem;
}

.cert-seal {
    font-size: 2rem;
}

.cert-title {
    text-align: center;
}

.cert-title h2 {
    font-size: 1.1rem;
    margin: 0 0 0.25rem 0;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.cert-title p {
    font-size: 0.75rem;
    color: #888;
    margin: 0;
}

.cert-body {
    padding: 0.5rem 0;
}

.cert-intro {
    text-align: center;
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 1rem;
}

.cert-project {
    text-align: center;
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: white;
    border-radius: 8px;
    border: 1px solid rgba(102, 126, 234, 0.15);
}

.cert-project-label {
    font-size: 0.75rem;
    color: #888;
    margin-bottom: 0.25rem;
}

.cert-project-name {
    font-size: 1.05rem;
    font-weight: 600;
    color: #333;
}

.cert-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.cert-radar-wrap {
    background: white;
    border-radius: 8px;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(102, 126, 234, 0.15);
}

.cert-radar-chart {
    width: 100%;
    max-width: 200px;
    height: auto;
}

.cert-scores {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.cert-score-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.3rem 0.5rem;
    background: white;
    border-radius: 6px;
    font-size: 0.78rem;
    color: #555;
    border: 1px solid rgba(102, 126, 234, 0.1);
}

.cert-score-item.cert-score-total {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    color: white;
    margin-top: 0.35rem;
    padding: 0.45rem 0.6rem;
    font-weight: 600;
}

.cert-score {
    font-weight: 600;
    color: #667eea;
}

.cert-score-total .cert-score {
    color: white;
    font-size: 1rem;
}

.cert-comment-box {
    background: white;
    border-radius: 8px;
    padding: 0.75rem;
    margin-bottom: 0.75rem;
    border: 1px solid rgba(102, 126, 234, 0.15);
}

.cert-comment-box h4 {
    font-size: 0.85rem;
    color: #555;
    margin: 0 0 0.5rem 0;
}

.cert-comment-box p {
    font-size: 0.82rem;
    color: #666;
    line-height: 1.6;
    margin: 0;
    white-space: pre-wrap;
}

.cert-self-box {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.03), rgba(118, 75, 162, 0.03));
}

.cert-footer {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 2px dashed rgba(102, 126, 234, 0.3);
}

.cert-footer-item {
    text-align: center;
    flex: 1;
}

.cert-footer-label {
    font-size: 0.7rem;
    color: #999;
    margin-bottom: 0.2rem;
}

.cert-footer-value {
    font-size: 0.78rem;
    color: #555;
    font-weight: 500;
}

.cert-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

.cert-actions .btn-secondary {
    flex: 1;
    margin: 0;
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
}

.cert-actions .btn-secondary:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

/* AI智能提示悬浮窗（跟随输入位置） */
.ai-tip-float {
    position: absolute;
    width: 260px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    box-shadow: 0 8px 32px rgba(102, 126, 234, 0.25);
    z-index: 900;
    overflow: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease;
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
}

.ai-tip-float.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.ai-tip-arrow {
    position: absolute;
    top: -8px;
    left: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid rgba(255, 255, 255, 0.98);
}

.ai-tip-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 0.82rem;
}

.ai-tip-icon {
    font-size: 1.2rem;
    line-height: 1;
}

.ai-tip-title {
    flex: 1;
    font-weight: 600;
}

.ai-tip-close {
    background: transparent;
    border: none;
    color: white;
    font-size: 1rem;
    cursor: pointer;
    padding: 0 0.25rem;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.ai-tip-close:hover {
    opacity: 1;
}

.ai-tip-body {
    padding: 0.75rem;
}

.ai-tip-content {
    min-height: 1.5rem;
}

.ai-tip-content p {
    margin: 0;
    color: #333;
    line-height: 1.5;
    font-size: 0.82rem;
}

.ai-tip-loading {
    display: flex;
    gap: 0.3rem;
    align-items: center;
    color: #667eea;
    font-size: 0.8rem;
}

.ai-tip-loading span:not(.ai-loading-text) {
    width: 6px;
    height: 6px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out both;
}

.ai-tip-loading span:nth-child(1) { animation-delay: -0.32s; }
.ai-tip-loading span:nth-child(2) { animation-delay: -0.16s; }
.ai-tip-loading span:nth-child(3) { animation-delay: 0s; }

.ai-loading-text {
    margin-left: 0.5rem;
}

.ai-tip-continue {
    margin-top: 0.6rem;
    padding-top: 0.6rem;
    border-top: 1px solid #e0e0e0;
}

.ai-tip-continue-btn {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 0.5rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.ai-tip-continue-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.ai-tip-float-top-header {
    display: none;
}

/* 左上角通用提示区域（非输入困难时显示） */
.ai-tip-top-left {
    position: fixed;
    top: 90px;
    left: 20px;
    width: 280px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(102, 126, 234, 0.25);
    z-index: 800;
    overflow: hidden;
    transition: opacity 0.4s ease, transform 0.4s ease;
    opacity: 0;
    transform: translateX(-20px);
    pointer-events: none;
}

.ai-tip-top-left.active {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.ai-tip-top-left-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.9rem;
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    color: white;
    font-size: 0.85rem;
}

.ai-tip-top-left-icon {
    font-size: 1rem;
}

.ai-tip-top-left-title {
    flex: 1;
    font-weight: 600;
}

.ai-tip-top-left-close {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0 0.25rem;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.ai-tip-top-left-close:hover {
    opacity: 1;
}

.ai-tip-top-left-content {
    padding: 0.9rem;
}

.ai-tip-top-left-content p {
    margin: 0;
    color: #333;
    line-height: 1.6;
    font-size: 0.85rem;
}

/* 内容区域调整 */
.section {
    padding-bottom: 2rem;
}

.site-footer {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1.5rem 0;
    margin-top: 2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.footer-content {
    text-align: center;
}

.beian-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #666;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.beian-link:hover {
    color: #764ba2;
    text-decoration: underline;
}

.beian-icon {
    font-size: 1.1rem;
    line-height: 1;
}

@media (max-width: 768px) {
    body {
        font-size: 15px;
    }

    .container {
        padding: 0 12px;
    }

    .header {
        padding: 0.75rem 0;
    }

    .header .container {
        flex-direction: column;
        gap: 0.75rem;
    }

    .logo-text {
        font-size: 1.1rem;
    }

    .nav {
        display: flex;
        flex-wrap: nowrap;
        gap: 0.3rem;
        overflow-x: auto;
        width: 100%;
        padding-bottom: 0.25rem;
        -webkit-overflow-scrolling: touch;
        justify-content: center;
    }

    .nav::-webkit-scrollbar {
        display: none;
    }

    .nav-link {
        padding: 0.4rem 0.75rem;
        font-size: 0.85rem;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .hero-content h1 {
        font-size: 1.8rem;
    }

    .hero-content p {
        font-size: 0.95rem;
    }

    .section {
        padding: 2rem 0;
    }

    .section-header h2 {
        font-size: 1.4rem;
    }

    .step-indicator {
        flex-wrap: wrap;
    }

    .step-line {
        width: 40px;
    }

    .step-num {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .step-name {
        font-size: 0.78rem;
    }

    .topic-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .topic-card {
        padding: 1.25rem;
    }

    .topic-card h3 {
        font-size: 1.05rem;
    }

    .topic-card p {
        font-size: 0.85rem;
    }

    .custom-topic {
        padding: 1rem;
        max-width: 100%;
    }

    .custom-topic input {
        font-size: 0.9rem;
        padding: 0.7rem 0.8rem;
    }

    .plan-container,
    .implement-container,
    .evaluation-card,
    .certificate {
        padding: 1rem;
        margin: 0;
    }

    .form-group {
        margin-bottom: 1rem;
    }

    .form-group label {
        font-size: 0.9rem;
    }

    .form-group input,
    .form-group textarea {
        font-size: 0.9rem;
        padding: 0.7rem 0.8rem;
    }

    .implement-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        margin-bottom: 1rem;
    }

    .implement-tabs::-webkit-scrollbar {
        display: none;
    }

    .tab-btn {
        padding: 0.6rem 0.9rem;
        font-size: 0.85rem;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .language-select,
    .comm-options {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .language-option,
    .comm-option {
        padding: 0.6rem 0.9rem;
        font-size: 0.85rem;
    }

    .student-info-box {
        padding: 1rem;
    }

    .student-info-row {
        flex-direction: column;
        gap: 0.8rem;
    }

    .student-info-buttons {
        flex-direction: column;
    }

    .student-info-buttons .btn-secondary {
        width: 100%;
    }

    .cert-layout {
        grid-template-columns: 1fr;
    }

    .cert-radar-chart {
        max-width: 180px;
    }

    .ai-assistant-icon {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
    }

    .ai-icon-emoji {
        font-size: 1.6rem;
    }

    .ai-chat-assistant {
        width: calc(100vw - 40px);
        max-width: 380px;
        height: 480px;
        max-height: calc(100vh - 120px);
        bottom: 20px;
        right: 20px;
    }

    .ai-tip-float {
        width: calc(100vw - 40px);
        max-width: 280px;
    }

    .ai-tip-top-left {
        width: calc(100vw - 40px);
        max-width: 260px;
        left: 20px;
        top: 110px;
    }

    .cert-footer {
        flex-direction: column;
        gap: 0.75rem;
    }

    .cert-actions {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 1.4rem;
    }

    .section-header h2 {
        font-size: 1.2rem;
    }

    .ai-chat-assistant {
        width: calc(100vw - 20px);
        right: 10px;
        bottom: 10px;
        height: 70vh;
    }

    .ai-assistant-icon {
        width: 45px;
        height: 45px;
        bottom: 15px;
        right: 15px;
    }

    .ai-tip-float,
    .ai-tip-top-left {
        width: calc(100vw - 30px);
        max-width: 260px;
    }
}

@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    body {
        -webkit-font-smoothing: antialiased;
    }
}

    .evaluation-card {
        padding: 1.5rem;
    }

    .ai-assistant-icon {
        width: 52px;
        height: 52px;
        bottom: 15px;
        right: 15px;
        font-size: 22px;
    }

    .ai-chat-assistant {
        width: calc(100vw - 20px);
        height: calc(100vh - 80px);
        max-height: 550px;
        right: 10px;
        bottom: 10px;
        left: 10px;
    }

    .ai-tip-float {
        width: calc(100vw - 40px);
        max-width: 260px;
    }

    .hero-content {
        padding: 2rem 0;
    }

    .hero-content h1 {
        font-size: 1.5rem;
    }

    .hero-content p {
        font-size: 0.95rem;
    }

    .section {
        padding: 2rem 0;
    }

    .section-header h2 {
        font-size: 1.3rem;
    }

    .section-header p {
        font-size: 0.9rem;
    }

    .form-group input,
    .form-group textarea {
        padding: 0.7rem 0.9rem;
        font-size: 0.9rem;
    }

    .custom-topic input {
        padding: 0.7rem 0.9rem;
        font-size: 0.9rem;
    }

    .btn-primary,
    .btn-secondary {
        padding: 0.65rem 1.3rem;
        font-size: 0.85rem;
    }

    .info-group input {
        padding: 0.6rem 0.9rem;
        font-size: 0.9rem;
    }

    .ai-chat-input-box input {
        font-size: 0.9rem;
        padding: 0.6rem 0.8rem;
    }

    .ai-chat-send {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
    }

    .ai-chat-bubble {
        font-size: 0.85rem;
        padding: 0.6rem 0.8rem;
    }

    .ai-tip-top-left {
        width: calc(100vw - 40px);
        max-width: 260px;
        top: 130px;
        left: 10px;
        right: 10px;
    }

    .implement-tabs button {
        padding: 0.6rem 0.8rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }

    .header {
        padding: 0.5rem 0;
    }

    .nav {
        gap: 0.25rem;
    }

    .nav-link {
        padding: 0.35rem 0.6rem;
        font-size: 0.78rem;
    }

    .hero-content h1 {
        font-size: 1.3rem;
    }

    .logo-text {
        font-size: 1rem;
    }

    .step-indicator {
        gap: 0.3rem;
    }

    .step-item {
        padding: 0.4rem 0.6rem;
        font-size: 0.75rem;
    }

    .ai-assistant-icon {
        width: 48px;
        height: 48px;
        bottom: 12px;
        right: 12px;
    }

    .ai-chat-assistant {
        width: calc(100vw - 16px);
        height: calc(100vh - 60px);
        right: 8px;
        bottom: 8px;
        left: 8px;
    }

    .plan-container,
    .implement-container {
        padding: 1rem;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }

    .form-group textarea {
        min-height: 100px;
    }

    .implement-tabs {
        flex-wrap: wrap;
    }

    .implement-tabs button {
        flex: 1;
        min-width: calc(50% - 5px);
    }

    .evaluation-card {
        padding: 1rem;
    }

    .ai-tip-float,
    .ai-tip-top-left {
        width: calc(100vw - 24px);
        max-width: none;
    }

    .ai-tip-top-left {
        top: 120px;
    }
}

@media (max-width: 360px) {
    .nav-link {
        padding: 0.3rem 0.5rem;
        font-size: 0.72rem;
    }

    .hero-content h1 {
        font-size: 1.15rem;
    }

    .implement-tabs button {
        min-width: 100%;
    }

    .student-info-row {
        gap: 0.5rem;
    }
}