/* =========================================
   1. 模板选择卡片样式 (保持不变)
   ========================================= */
.template-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 5px;
}
@media screen and (max-width: 768px) {
    .template-grid { grid-template-columns: 1fr; }
}
.template-card {
    border: 1px solid #dcdfe6;
    border-radius: 8px;
    padding: 20px 15px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    transition: all 0.3s;
    background: #fff;
    position: relative;
    height: 100%;

}
.template-card:hover {
    border-color: #409eff;
    box-shadow: 0 4px 12px rgba(64, 158, 255, 0.15);
    transform: translateY(-2px);
}
.template-card.active {
    border-color: #409eff;
    background-color: #ecf5ff;
}
.template-card .tpl-icon { font-size: 32px; color: #909399; margin-bottom: 12px; }
.template-card.active .tpl-icon { color: #409eff; }
.template-card .tpl-name { font-weight: bold; font-size: 15px; color: #303133; }
.template-card .tpl-desc { font-size: 12px; color: #909399; line-height: 1.5; }
.template-card .check-mark { position: absolute; top: 8px; right: 8px; color: #409eff; font-size: 18px; display: none; }
.template-card.active .check-mark { display: block; }


/* =========================================
   2. 全要素教案文档样式 (New Standard Style)
   ========================================= */

/* 文档主容器：模拟 A4 纸 */
.jiaoan-preview-box {
    background: #fff;
    padding: 60px 50px; /* 宽大的页边距 */
    border: 1px solid #dcdcdc;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    font-family: "SimSun", "Songti SC", "Noto Serif SC", serif; /* 宋体 */
    color: #2c3e50;
    line-height: 1.8;
    margin-top: 20px;
}

/* 标题区 */
.doc-header {
    text-align: center;
    margin-bottom: 40px;
    border-bottom: 2px solid #333;
    padding-bottom: 20px;
}

.main-title {
    font-size: 28px;
    font-weight: 900;
    color: #000;
    margin: 0 0 20px 0;
    font-family: "SimHei", sans-serif; /* 黑体 */
}

.info-grid {
    display: flex;
    justify-content: center;
    gap: 30px;
    font-size: 15px;
}

/* 章节通用样式 */
.doc-section {
    margin-bottom: 30px;
}

.section-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 15px;
    padding-left: 10px;
    border-left: 5px solid #409eff; /* 蓝色竖条装饰 */
    font-family: "SimHei", sans-serif;
    color: #333;
    background: #f9fafc;
    padding: 8px 10px;
}

.section-content {
    font-size: 16px;
    text-align: justify;
    padding-left: 10px;
}

/* 列表优化 */
.section-content ul {
    list-style-type: disc;
    padding-left: 20px;
    margin: 5px 0;
}
.section-content li {
    margin-bottom: 5px;
}

/* --- 核心表格样式 --- */
.process-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    table-layout: fixed;
    font-size: 15px;
}

.process-table th, 
.process-table td {
    border: 1px solid #000; /* 黑色实线 */
    padding: 12px;
    vertical-align: top;
    word-break: break-word;
}

.process-table th {
    background-color: #eef1f6;
    font-weight: bold;
    text-align: center;
    color: #000;
}

/* 板书设计盒子 */
.board-design-box {
    border: 2px dashed #999;
    padding: 20px;
    border-radius: 4px;
    background-color: #fffbf0; /* 模仿黑板/白板的微黄色 */
    min-height: 100px;
}

/* 手机端适配 */
@media screen and (max-width: 768px) {
    .jiaoan-preview-box { padding: 20px; }
    .info-grid { flex-direction: column; gap: 5px; text-align: left; }
    .process-table, .process-table tbody, .process-table tr, .process-table td {
        display: block; width: 100%;
    }
    .process-table thead { display: none; } /* 手机上隐藏表头 */
    .process-table tr { margin-bottom: 15px; border: 1px solid #ccc; }
    .process-table td { border: none; border-bottom: 1px solid #eee; position: relative; padding-left: 35%; }
    .process-table td::before {
        content: attr(data-label); /* 需要配合JS，这里简单处理即可 */
        position: absolute; left: 10px; font-weight: bold;
    }
}


/* =========================================
   3. 比赛级·教学评一体化 专属样式
   ========================================= */

/* 头部美化 */
.doc-header-contest {
    text-align: center;
    border-bottom: 3px double #333;
    padding-bottom: 20px;
    margin-bottom: 30px;
    background: #fdfdfd;
}
.contest-title {
    font-size: 32px;
    font-family: "SimHei", "Microsoft YaHei", sans-serif;
    margin-bottom: 15px;
}
.contest-info {
    display: flex;
    justify-content: center;
    gap: 20px;
}
.info-box {
    border: 1px solid #333;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 14px;
    background: #fff;
}

/* 左右分栏的分析块 */
.analysis-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.analysis-item {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 6px;
    border-left: 4px solid #dcdfe6;
}
.analysis-item h4 {
    margin-top: 0;
    font-size: 16px;
    color: #444;
}

/* --- 核心：教学评表格 --- */
.contest-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    table-layout: fixed; /* 固定列宽，防止撑破 */
}
.contest-table th {
    background-color: #eef1f6; /* 浅蓝灰底色 */
    color: #333;
    padding: 10px 5px;
    border: 1px solid #000;
    text-align: center;
    vertical-align: middle;
}
.contest-table td {
    border: 1px solid #000;
    padding: 10px;
    vertical-align: top;
    word-wrap: break-word;
}

/* 强调列 */
.contest-table td:nth-child(4) { 
    background-color: #fffbf0; /* 评价任务列微黄，突出重点 */
}

/* 手机适配 */
@media screen and (max-width: 768px) {
    .analysis-grid { grid-template-columns: 1fr; }
    .contest-table, .contest-table tbody, .contest-table tr, .contest-table td {
        display: block; width: 100%;
    }
    .contest-table thead { display: none; }
    .contest-table tr { margin-bottom: 20px; border: 2px solid #eee; }
    .contest-table td { 
        border: none; 
        border-bottom: 1px solid #eee; 
        position: relative;
        padding-left: 10px; 
    }
}
/* =========================================
   4. 比赛级专用样式 (Contest Mode)
   ========================================= */

.contest-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    font-size: 14px;
    font-family: "SimSun", "Songti SC", serif; /* 模仿公文宋体 */
}

.contest-table th, 
.contest-table td {
    border: 1px solid #333; /* 深色边框 */
    padding: 10px;
    line-height: 1.6;
}

.contest-table th {
    background-color: #f5f5f5;
    text-align: center;
    font-weight: bold;
}

/* 教学活动列里的 小标题 */
.activity-box strong {
    color: #333;
    font-weight: bold;
}

/* 移动端适配 */
@media screen and (max-width: 768px) {
    .contest-table, .contest-table tbody, .contest-table tr, .contest-table td {
        display: block; width: 100%;
    }
    .contest-table td {
        text-align: left !important; /* 强制左对齐 */
        border-bottom: none;
    }
    .contest-table td:last-child {
        border-bottom: 2px solid #333;
        background-color: #fffbf0; /* 评价要点在手机上高亮 */
    }
}