:root {
    --primary-color: #007AFF;
    --secondary-color: #34C759;
    --accent-color: #FF9500;
    --background-color: #FFFFFF;
    --text-primary: #1C1C1E;
    --text-secondary: #8E8E93;
    --border-color: #D1D1D6;
    --section-bg: #FAFAFA;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--background-color);
    color: var(--text-primary);
    padding-top: 50px;
    padding-bottom: 70px;
}

/* 顶部导航栏 */
.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 50px;
    background: white;
    display: flex;
    align-items: center;
    padding: 0 16px;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.back-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--section-bg);
    color: var(--text-primary);
}

.page-title {
    flex: 1;
    text-align: center;
    font-size: 18px;
    font-weight: 600;
    margin: 0 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 课程标题区域 */
.lesson-header {
    padding: 20px 16px;
    background: var(--section-bg);
    border-bottom: 1px solid var(--border-color);
}

.lesson-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.lesson-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
}

.meta-item {
    display: flex;
    align-items: center;
    font-size: 14px;
    color: var(--text-secondary);
}

.meta-item i {
    margin-right: 6px;
    color: var(--primary-color);
}

.action-buttons {
    display: flex;
    gap: 12px;
}

.action-btn {
    flex: 1;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    font-size: 15px;
    transition: all 0.2s ease;
    border: 1px solid var(--border-color);
    background: white;
    color: var(--text-primary);
}

.action-btn.primary {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* 内容区域 */
.section {
    padding: 0 16px;
    margin-bottom: 24px;
}

.section-header {
    display: flex;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-color);
}

.section-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
}

.section-title-icon {
    margin-right: 10px;
    color: var(--primary-color);
}

.lesson-content {
    padding: 16px 0;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-primary);
}

.lesson-content p {
    margin-bottom: 16px;
}

/* 古诗内容区域 - 素凑型设计（优化诗人展示） */
.poem-section {
    padding: 12px 0;
}

.poem-container {
    background: url('/mobile/1761873049823_0.jpg') center/cover no-repeat;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    min-height: 160px; /* 进一步减小最小高度 */
    margin-bottom: 16px;
    font-family: '楷体', 'STKaiti', '华文楷体', serif;
}

.poem-header {
    text-align: center;
    padding: 16px 20px 8px; /* 根据规范调整内边距 */
}

.poem-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px; /* 根据规范调整间距 */
    color: #333;
    font-family: '楷体', 'STKaiti', '华文楷体', serif;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.95); /* 提升背景图片清晰度 */
}

.poem-author {
    font-size: 16px;
    color: #666;
    margin-bottom: 0;
    font-style: italic;
    font-family: '楷体', 'STKaiti', '华文楷体', serif;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.95); /* 提升背景图片清晰度 */
}

.poem-content {
    text-align: center;
    padding: 8px 20px 16px; /* 根据规范调整内边距 */
    font-family: '楷体', 'STKaiti', '华文楷体', serif;
}

.poem-text {
    font-size: 18px;
    line-height: 2;
    margin-bottom: 12px; /* 根据规范调整间距 */
    color: #333;
    font-family: '楷体', 'STKaiti', '华文楷体', serif;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.95); /* 提升背景图片清晰度 */
}

.poem-line {
    margin-bottom: 12px; /* 根据规范调整行间距 */
    color: #333;
    font-family: '楷体', 'STKaiti', '华文楷体', serif;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.95); /* 提升背景图片清晰度 */
}

.poem-line:last-child {
    margin-bottom: 0;
}

.poem-actions {
    text-align: center;
    padding-bottom: 16px;
}

.action-btn.primary {
    background: linear-gradient(135deg, #007AFF 0%, #0066cc 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 24px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
    transition: all 0.2s ease;
    font-family: '楷体', 'STKaiti', '华文楷体', serif;
}

.action-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.4);
}

.action-btn.primary:active {
    transform: translateY(0);
    box-shadow: 0 1px 4px rgba(0, 122, 255, 0.3);
}

.action-btn.primary i {
    font-size: 16px;
}

/* 注释与翻译部分 - 优化移动端体验 */
.annotations-content {
    padding: 12px 0;
}

.annotation-item {
    margin-bottom: 10px; /* 减小间距 */
    padding-bottom: 10px; /* 减小间距 */
    border-bottom: 1px dashed var(--border-color);
}

.annotation-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.annotation-term {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 15px; /* 调整字体大小 */
}

.annotation-explanation {
    color: var(--text-primary);
    font-size: 15px; /* 调整字体大小 */
    line-height: 1.5; /* 调整行高 */
}

.translation-section {
    margin-top: 16px; /* 减小间距 */
    padding-top: 16px; /* 减小间距 */
    border-top: 1px solid var(--border-color);
}

.translation-title {
    font-weight: 600;
    margin-bottom: 8px; /* 减小间距 */
    color: var(--primary-color);
    font-size: 16px; /* 调整字体大小 */
}

.translation-content {
    color: var(--text-primary);
    font-size: 15px; /* 调整字体大小 */
    line-height: 1.6; /* 调整行高 */
}

/* 诗句理解部分 - 优化移动端体验 */
.understanding-content {
    padding: 12px 0;
}

.understanding-item {
    margin-bottom: 10px; /* 减小间距 */
    padding-bottom: 10px; /* 减小间距 */
    border-bottom: 1px dashed var(--border-color);
}

.understanding-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.understanding-term {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 15px; /* 调整字体大小 */
}

.understanding-explanation {
    color: var(--text-primary);
    font-size: 15px; /* 调整字体大小 */
    line-height: 1.5; /* 调整行高 */
}

/* 诗歌赏析部分 - 优化移动端体验 */
.appreciation-content {
    padding: 12px 0;
}

.appreciation-content.bg-yellow-50 {
    background-color: #fef9c3; /* yellow-50 */
    padding: 0.75rem; /* 减小内边距 */
    border-radius: 0.5rem;
    border: 1px solid #fef08a; /* yellow-100 */
    margin-bottom: 1rem; /* 减小底部间距 */
}

.appreciation-item {
    margin-bottom: 10px; /* 减小间距 */
    padding-bottom: 10px; /* 减小间距 */
    border-bottom: 1px dashed var(--border-color);
}

.appreciation-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.appreciation-term {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 15px; /* 调整字体大小 */
}

.appreciation-explanation {
    color: var(--text-primary);
    font-size: 15px; /* 调整字体大小 */
    line-height: 1.5; /* 调整行高 */
}

/* 为诗歌赏析添加PC端一致的内部样式 */
.appreciation-content .font-medium {
    font-weight: 600;
}

.appreciation-content .text-gray-700 {
    color: var(--text-primary);
}

/* 星星图标样式 */
.appreciation-content .text-yellow-500 {
    color: #eab308; /* yellow-500 */
}

.appreciation-content .mt-1 {
    margin-top: 0.25rem;
}

.appreciation-content .mr-2 {
    margin-right: 0.5rem;
}

.appreciation-content .space-y-3 > div:not(:last-child) {
    margin-bottom: 0.75rem;
}

/* 创作背景部分 - 重新设计 */
.creation-background-content {
    padding: 12px 0;
}

.creation-content-wrapper {
    background: linear-gradient(135deg, #f0f8ff 0%, #e6f2ff 100%);
    border-radius: 12px;
    padding: 16px;
    border: 1px solid #d0e1ff;
    position: relative;
    overflow: hidden;
}

.creation-content-wrapper::before {
    content: "";
    position: absolute;
    top: -10px;
    right: -10px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 122, 255, 0.1);
    z-index: 0;
}

.creation-content-wrapper::after {
    content: "";
    position: absolute;
    bottom: -15px;
    left: -15px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(0, 122, 255, 0.05);
    z-index: 0;
}

.creation-text {
    position: relative;
    z-index: 1;
    color: #2c3e50;
    font-size: 15px;
    line-height: 1.7;
    text-align: justify;
}

.creation-text p {
    margin: 0 0 12px 0;
}

.creation-text p:last-child {
    margin-bottom: 0;
}

/* 生字学习部分 - 优化移动端体验 */
.characters-content {
    padding: 12px 0; /* 减小内边距 */
}

.character-item {
    display: flex;
    align-items: center;
    margin-bottom: 12px; /* 减小间距 */
    padding-bottom: 12px; /* 减小间距 */
    border-bottom: 1px dashed var(--border-color);
}

.character-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.character {
    font-size: 28px; /* 减小字体大小 */
    font-weight: 700;
    width: 50px; /* 减小宽度 */
    height: 50px; /* 减小高度 */
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--section-bg);
    border-radius: 10px; /* 减小圆角 */
    margin-right: 12px; /* 减小右边距 */
    color: var(--primary-color);
}

.character-info {
    flex: 1;
}

.pinyin {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 3px; /* 减小间距 */
    font-size: 14px; /* 减小字体大小 */
}

.meaning {
    color: var(--text-secondary);
    font-size: 14px; /* 减小字体大小 */
}

/* 诗人介绍部分 - 优化移动端体验 */
.poet-content {
    padding: 12px 0;
    color: var(--text-primary);
}

.poet-content.bg-gradient-to-r {
    background: linear-gradient(135deg, #fef9c3 0%, #fde68a 100%);
    border-radius: 12px;
    border: 1px solid #fde68a;
    padding: 16px;
    margin: 12px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.poet-content .prose {
    color: #374151;
    font-size: 15px; /* 减小字体大小 */
    line-height: 1.6; /* 调整行高 */
}

.poet-content .prose p {
    margin-bottom: 12px; /* 减小段落间距 */
}

.poet-content .prose p:last-child {
    margin-bottom: 0;
}

/* 诗人介绍中的按钮样式 */
.poet-content a.poet-action-btn {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(135deg, #007AFF 0%, #0066cc 100%);
    color: white;
    padding: 12px 20px;
    border-radius: 24px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
    border: none;
}

.poet-content a.poet-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.4);
}

.poet-content a.poet-action-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 4px rgba(0, 122, 255, 0.3);
}

.poet-content a.poet-action-btn i {
    margin-right: 8px;
}

.poet-action {
    margin-top: 16px; /* 减小顶部间距 */
    text-align: center;
}

.poet-action .inline-flex {
    display: inline-flex;
    align-items: center;
    background-color: var(--primary-color);
    color: white;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease; /* 统一过渡效果 */
    box-shadow: 0 2px 4px rgba(0, 122, 255, 0.2); /* 添加阴影 */
}

.poet-action .inline-flex:hover {
    background-color: #0066cc;
    transform: translateY(-2px); /* 添加悬浮效果 */
    box-shadow: 0 4px 8px rgba(0, 122, 255, 0.3);
}

.poet-action .inline-flex:active {
    transform: translateY(0); /* 按下时的效果 */
    box-shadow: 0 1px 2px rgba(0, 122, 255, 0.2);
}

.poet-action .inline-flex i {
    margin-right: 8px;
}

/* 文化拓展部分 - 优化移动端体验 */
.culture-content {
    padding: 12px 0; /* 减小内边距 */
    color: var(--text-primary);
}

.culture-content.bg-blue-50 {
    background-color: #dbeafe;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 12px; /* 减小内边距 */
    margin: 12px 0; /* 减小间距 */
}

.culture-content .prose {
    color: #374151;
    font-size: 15px; /* 减小字体大小 */
    line-height: 1.6; /* 调整行高 */
}

.culture-content .prose p {
    margin-bottom: 12px; /* 减小段落间距 */
}

.culture-content .prose p:last-child {
    margin-bottom: 0;
}

/* 朗读指导部分 - 优化移动端体验 */
.reading-content {
    padding: 12px 0; /* 减小内边距 */
    color: var(--text-primary);
}

.reading-content.bg-purple-50 {
    background-color: #f3e8ff;
    border: 1px solid #e9d5ff;
    border-radius: 8px;
    padding: 12px; /* 减小内边距 */
    margin: 12px 0; /* 减小间距 */
}

.reading-content .prose {
    color: #374151;
    font-size: 15px; /* 减小字体大小 */
    line-height: 1.6; /* 调整行高 */
}

.reading-content .prose p {
    margin-bottom: 12px; /* 减小段落间距 */
}

.reading-content .prose p:last-child {
    margin-bottom: 0;
}

/* 相关名句部分 - 优化移动端体验 */
.quotes-content {
    padding: 12px 0; /* 减小内边距 */
    color: var(--text-primary);
}

.quotes-content.bg-red-50 {
    background-color: #fee2e2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    padding: 12px; /* 减小内边距 */
    margin: 12px 0; /* 减小间距 */
}

.quotes-content .prose {
    color: #374151;
    font-size: 15px; /* 减小字体大小 */
    line-height: 1.6; /* 调整行高 */
}

.quotes-content .prose p {
    margin-bottom: 12px; /* 减小段落间距 */
}

.quotes-content .prose p:last-child {
    margin-bottom: 0;
}

/* 课堂练习 */
.exercise-list {
    padding: 16px 0;
}

.exercise-item {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px dashed var(--border-color);
}

.exercise-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.exercise-question {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.exercise-options {
    padding-left: 20px;
}

.exercise-option {
    margin-bottom: 10px;
    font-size: 15px;
    color: var(--text-secondary);
    display: flex;
    align-items: flex-start;
}

.exercise-option:before {
    content: "•";
    margin-right: 8px;
    color: var(--primary-color);
}

/* 课程导航 */
.navigation-list {
    padding: 16px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-color);
}

.nav-item:last-child {
    border-bottom: none;
}

.nav-item.active {
    color: var(--primary-color);
    font-weight: 600;
}

.nav-item i {
    margin-right: 12px;
    width: 24px;
    text-align: center;
    color: var(--primary-color);
}

.nav-item .lesson-number {
    margin-right: 10px;
    font-weight: 600;
    color: var(--primary-color);
}

/* 底部导航 */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: white;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 10px 0;
    border-top: 1px solid var(--border-color);
    z-index: 1000;
}

.nav-item-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--text-secondary);
    flex: 1;
}

.nav-item-bottom.active {
    color: var(--primary-color);
}

.nav-icon {
    font-size: 22px;
    margin-bottom: 4px;
}

.nav-label {
    font-size: 12px;
    font-weight: 500;
}

/* 响应式优化 */
@media (max-width: 480px) {
    .lesson-title {
        font-size: 22px;
    }
    
    .section-title {
        font-size: 18px;
    }
    
    .lesson-content {
        font-size: 15px;
    }
    
    .poem-title {
        font-size: 22px;
    }
    
    .poem-content {
        font-size: 16px;
        padding: 16px;
    }
    
    .exercise-question {
        font-size: 16px;
    }
    
    .exercise-option {
        font-size: 14px;
    }
    
    .character {
        font-size: 28px;
        width: 50px;
        height: 50px;
    }
}

/* 添加.pt-16样式 */
.pt-16 {
    padding-top: 0.5rem;
}