/* ========================================
   TEFL 网 站 — 公共样式表
   学术绿主题 v3（Cathy 2026-08-13 定）
   主色：#2D6A4F(深学术绿) #40916C(中绿) #52B788(鼠尾草/扫码色) #95D5B2(薄荷)
   强调：#52B788(鼠尾草/证书章) #1B4332(深绿-页脚)
   ======================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
    font-family: "Microsoft YaHei", "微软雅黑", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
    color: #2c3e3a;
    background: #f5f9f6;
    line-height: 1.7;
    font-size: 14px;
}

a { color: #2D6A4F; text-decoration: none; transition: color .2s; }
a:hover { color: #40916C; }

img { max-width: 100%; height: auto; display: block; }

/* ====== 顶部 LOGO 区 ====== */
.topbar {
    background: #fff;
    border-bottom: 1px solid #e0ece4;
    padding: 14px 0;
}
.topbar-inner {
    width: 1000px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.topbar-inner .logo img { height: 70px; }
.topbar-inner .lang {
    font-size: 12px;
    color: #888;
}
.topbar-inner .lang a { margin: 0 4px; }

/* 快捷入口 */
.quick-links {
    display: flex;
    gap: 4px;
}
.quick-links a {
    display: inline-block;
    padding: 6px 16px;
    background: #40916C;
    color: #fff !important;
    border-radius: 4px;
    font-size: 13px;
    font-weight: bold;
}
.quick-links a:hover { background: #2D6A4F; }

/* ====== 主导航 ====== */
.mainnav {
    background: linear-gradient(180deg, #2D6A4F 0%, #1B4332 100%);
    box-shadow: 0 2px 4px rgba(27,67,50,.15);
}
.mainnav-inner {
    width: 1000px;
    margin: 0 auto;
    display: flex;
}
.mainnav-inner a {
    flex: 1;
    color: #fff;
    padding: 12px 0;
    text-align: center;
    font-weight: bold;
    font-size: 12px;
    line-height: 1.4;
    white-space: nowrap;
    border-right: 1px solid rgba(255,255,255,.12);
    transition: background .2s;
}
.mainnav-inner a:last-child { border-right: none; }
.mainnav-inner a:hover, .mainnav-inner a.active {
    background: #52B788;
    color: #fff;
}

/* ====== 公告滚动条 ====== */
.ticker {
    background: #fff;
    border: 1px solid #d8e7df;
    border-radius: 4px;
    padding: 10px 16px;
    margin: 16px auto;
    width: 1000px;
    display: flex;
    align-items: center;
    overflow: hidden;
}
.ticker-label {
    background: #2D6A4F;
    color: #fff;
    padding: 4px 12px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
    flex-shrink: 0;
    margin-right: 12px;
}
.ticker-text {
    color: #555;
    font-size: 13px;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ====== 主内容容器 ====== */
.container {
    width: 1000px;
    margin: 0 auto;
    padding: 20px 0;
}

/* ====== 首页：证书首要位置板块 ====== */
.cert-priority {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(45,106,79,.08);
    padding: 30px;
    margin-bottom: 24px;
    border-top: 4px solid #52B788;
}
.section-title {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #e0ece4;
}
.section-title .icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #95D5B2 0%, #52B788 100%);
    color: #fff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-right: 12px;
    box-shadow: 0 2px 4px rgba(82,183,136,.3);
}
.section-title h2 {
    font-size: 22px;
    color: #1B4332;
    font-weight: bold;
    flex: 1;
}
.section-title .sub {
    color: #888;
    font-size: 12px;
    font-weight: normal;
    margin-left: 8px;
}
.section-title .more {
    color: #2D6A4F;
    font-size: 12px;
}

/* 证书卡片网格 */
.cert-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.cert-card {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    background: linear-gradient(135deg, #f6faf7 0%, #fff 100%);
    border: 1px solid #d8e7df;
    border-left: 4px solid #52B788;
    border-radius: 6px;
    transition: all .25s;
    text-decoration: none;
    color: #2c3e3a;
}
.cert-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(82,183,136,.18);
    border-left-color: #40916C;
    color: #2c3e3a;
}
.cert-card .badge {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #95D5B2 0%, #52B788 100%);
    color: #fff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 12px;
    flex-shrink: 0;
    margin-right: 12px;
}
.cert-card .info { flex: 1; }
.cert-card .info .name {
    font-weight: bold;
    font-size: 14px;
    color: #1B4332;
    margin-bottom: 4px;
}
.cert-card .info .meta {
    color: #888;
    font-size: 12px;
}

/* ====== 通用板块（白底卡片） ====== */
.block {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(45,106,79,.06);
    padding: 24px;
    margin-bottom: 20px;
}
.block .section-title { margin-bottom: 16px; }

/* ====== 首页头部紧凑（仅 .index-top-compact 启用）v4.7 ====== */
.index-top-compact .ticker { margin: 8px auto 6px; }
.index-top-compact .container { padding-top: 6px; }
.index-top-compact .container > section.block,
.index-top-compact .container > section.cert-priority {
    padding: 16px 22px;
    margin-bottom: 12px;
}
.index-top-compact .container > section.block .section-title,
.index-top-compact .container > section.cert-priority .section-title {
    margin-bottom: 12px;
    padding-bottom: 8px;
}

/* ====== 课程网格 ====== */
.course-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}
.course-card {
    background: #fafdfb;
    border: 1px solid #d8e7df;
    border-radius: 6px;
    overflow: hidden;
    transition: all .25s;
    text-decoration: none;
    color: #2c3e3a;
    display: block;
}
.course-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(45,106,79,.18);
    color: #2c3e3a;
}
.course-card .cover {
    width: 100%;
    height: 260px;
    background: #fff;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
}
.course-card .body {
    padding: 10px 12px;
    position: relative;
}
.course-card .body .units {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #E8F5EE;
    color: #2D6A4F;
    padding: 2px 10px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: bold;
}
.course-card .body .name {
    font-size: 13px;
    font-weight: bold;
    color: #1B4332;
    margin-bottom: 4px;
}
.course-card .body .meta {
    font-size: 11px;
    color: #888;
}

/* ====== 教材卡片 ====== */
.book-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
.book-card {
    background: #fff;
    border: 1px solid #d8e7df;
    border-radius: 6px;
    overflow: hidden;
    text-align: center;
    transition: all .25s;
    text-decoration: none;
    color: #2c3e3a;
    padding-bottom: 12px;
}
.book-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,.1);
    color: #2c3e3a;
}
.book-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-bottom: 1px solid #d8e7df;
}
.book-card .title {
    padding: 10px 12px 4px;
    font-weight: bold;
    color: #1B4332;
    font-size: 13px;
}
.book-card .meta {
    color: #888;
    font-size: 11px;
    padding: 0 12px;
}

/* ====== 教师卡片 ====== */
.teacher-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
.teacher-card {
    background: #fff;
    border: 1px solid #d8e7df;
    border-radius: 6px;
    overflow: hidden;
    text-align: center;
    padding: 16px 12px;
    transition: all .25s;
}
.teacher-card:hover {
    box-shadow: 0 4px 12px rgba(45,106,79,.15);
}
.teacher-card img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto 10px;
    border: 3px solid #d8e7df;
}
.teacher-card .name {
    font-weight: bold;
    color: #1B4332;
    font-size: 14px;
    margin-bottom: 4px;
}
.teacher-card .title {
    color: #2D6A4F;
    font-size: 12px;
    margin-bottom: 6px;
}
.teacher-card .meta {
    color: #888;
    font-size: 11px;
    line-height: 1.6;
}

/* ====== 历届培训：图片廊 ====== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.gallery-grid .item {
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid #d8e7df;
}
.gallery-grid img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: transform .3s;
}
.gallery-grid .item:hover img { transform: scale(1.05); }
.gallery-grid .caption {
    padding: 8px 10px;
    font-size: 12px;
    color: #555;
    background: #f6faf7;
    text-align: center;
}

/* ====== 学员留言 ====== */
.comments {
    background: #f6faf7;
    border-left: 3px solid #40916C;
    padding: 12px 16px;
    margin-bottom: 10px;
    border-radius: 4px;
    color: #555;
    font-size: 13px;
    line-height: 1.8;
}
.comments::before { content: "\201C"; color: #2D6A4F; font-size: 22px; font-weight: bold; margin-right: 6px; }
.comments::after { content: "\201D"; color: #2D6A4F; font-size: 22px; font-weight: bold; margin-left: 4px; }

/* ====== 新闻列表 ====== */
.news-list { list-style: none; }
.news-list li {
    border-bottom: 1px dashed #d8e7df;
    padding: 10px 0;
    display: flex;
    align-items: center;
}
.news-list li::before {
    content: "\25B8";
    color: #40916C;
    margin-right: 8px;
    font-size: 12px;
}
.news-list a {
    flex: 1;
    color: #2c3e3a;
    font-size: 14px;
}
.news-list a:hover { color: #2D6A4F; }
.news-list .date {
    color: #999;
    font-size: 12px;
    flex-shrink: 0;
    margin-left: 12px;
}

/* ====== 关于我们 / 文章详情 ====== */
.article {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(45,106,79,.06);
    padding: 30px;
    margin-bottom: 20px;
}
.article h1 {
    font-size: 22px;
    color: #1B4332;
    text-align: center;
    margin-bottom: 8px;
}
.article .crumbs {
    text-align: center;
    color: #999;
    font-size: 12px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px dashed #d8e7df;
}
.article .crumbs a { color: #2D6A4F; }
.article h2 {
    font-size: 18px;
    color: #1B4332;
    margin: 24px 0 12px;
    padding-left: 12px;
    border-left: 4px solid #2D6A4F;
}
.article h3 {
    font-size: 16px;
    color: #2D6A4F;
    margin: 20px 0 10px;
}
.article p {
    margin-bottom: 12px;
    color: #555;
    line-height: 1.9;
    text-indent: 2em;
}
.article .lead {
    text-indent: 0;
    color: #333;
    font-size: 15px;
    background: #f6faf7;
    padding: 16px;
    border-radius: 4px;
    border-left: 3px solid #52B788;
    margin-bottom: 20px;
}
.article img { margin: 12px auto; border-radius: 4px; box-shadow: 0 2px 8px rgba(0,0,0,.1); }
.article .cert-img {
    width: 100%;
    max-width: 660px;
    margin: 16px auto;
}
.article .video-list {
    list-style: none;
    margin: 16px 0;
}
.article .video-list li {
    background: #fafdfb;
    border: 1px solid #d8e7df;
    border-left: 4px solid #2D6A4F;
    padding: 10px 16px;
    margin-bottom: 8px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    transition: all .2s;
}
.article .video-list li:hover {
    background: #fff;
    box-shadow: 0 2px 6px rgba(45,106,79,.12);
}
.article .video-list .unit {
    background: #2D6A4F;
    color: #fff;
    padding: 4px 10px;
    border-radius: 3px;
    font-weight: bold;
    font-size: 13px;
    margin-right: 12px;
    flex-shrink: 0;
}
.article .video-list a { flex: 1; }
.article .video-list .dur { color: #888; font-size: 12px; }

/* ====== 证书样品图 ====== */
.cert-sample {
    text-align: center;
    margin: 24px 0;
}
.cert-sample .label {
    font-size: 15px;
    color: #1B4332;
    font-weight: bold;
    margin-bottom: 10px;
}
.cert-sample img {
    max-width: 100%;
    width: 660px;
    margin: 0 auto;
    border: 1px solid #d8e7df;
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0,0,0,.08);
}

/* ====== 报名表 / CTA 按钮 ====== */
.cta {
    display: inline-block;
    background: linear-gradient(180deg, #40916C 0%, #2D6A4F 100%);
    color: #fff;
    padding: 10px 28px;
    border-radius: 4px;
    font-weight: bold;
    text-decoration: none;
    margin-top: 12px;
    box-shadow: 0 2px 4px rgba(45,106,79,.3);
    transition: all .2s;
}
.cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(45,106,79,.4);
    color: #fff;
}

/* ====== 团队列表（详细） ====== */
.teacher-detail {
    display: flex;
    background: #fff;
    border: 1px solid #d8e7df;
    border-radius: 6px;
    padding: 16px;
    margin-bottom: 12px;
    transition: all .2s;
}
.teacher-detail:hover { box-shadow: 0 2px 8px rgba(45,106,79,.1); }
.teacher-detail img {
    width: 110px;
    height: 140px;
    object-fit: cover;
    border-radius: 4px;
    margin-right: 16px;
    flex-shrink: 0;
}
.teacher-detail .info { flex: 1; }
.teacher-detail .info .name { font-size: 16px; color: #1B4332; font-weight: bold; margin-bottom: 6px; }
.teacher-detail .info .row { color: #666; font-size: 13px; margin-bottom: 4px; }
.teacher-detail .info .row strong { color: #2D6A4F; display: inline-block; min-width: 80px; }

/* ====== 底部 ====== */
.footer {
    background: #1B4332;
    color: #cfdfd8;
    margin-top: 40px;
    padding: 30px 0 16px;
}
.footer-inner {
    width: 1000px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}
.footer h4 {
    color: #fff;
    font-size: 14px;
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid #2d5e44;
}
.footer p, .footer a { color: #cfdfd8; font-size: 12px; line-height: 1.9; }
.footer a:hover { color: #95D5B2; }
.footer-bottom {
    width: 1000px;
    margin: 20px auto 0;
    border-top: 1px solid #2d5e44;
    padding-top: 12px;
    text-align: center;
    color: #95b3a4;
    font-size: 12px;
}
.footer-col { flex: 1; min-width: 200px; padding: 0 16px; }
.footer-col .wechat-mini img { width: 110px; height: 110px; border: 1px solid #2d5e44; border-radius: 4px; padding: 4px; background: #fff; }
.footer-col .wechat-mini .label { color: #95D5B2; font-size: 12px; margin-top: 6px; }

/* ====== 视频课程页：左侧栏章节列表 ====== */
.course-layout {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 20px;
    margin-bottom: 20px;
}
.course-sidebar {
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(45,106,79,.06);
    padding: 16px;
    height: fit-content;
    position: sticky;
    top: 16px;
}
.course-sidebar h3 {
    color: #1B4332;
    font-size: 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid #2D6A4F;
    margin-bottom: 12px;
}
.course-sidebar .ep {
    padding: 10px 12px;
    background: #fafdfb;
    border: 1px solid #d8e7df;
    border-left: 3px solid #2D6A4F;
    margin-bottom: 6px;
    border-radius: 3px;
    font-size: 13px;
    color: #555;
    cursor: pointer;
    transition: all .2s;
}
.course-sidebar .ep:hover {
    background: #2D6A4F;
    color: #fff;
    border-left-color: #52B788;
}
.course-sidebar .ep .ep-no {
    display: inline-block;
    background: #2D6A4F;
    color: #fff;
    padding: 1px 6px;
    border-radius: 2px;
    font-size: 11px;
    margin-right: 6px;
}
.course-sidebar .ep:hover .ep-no { background: #fff; color: #2D6A4F; }

/* ====== 联系信息块（联系我们/关于我们/合作加盟） ====== */
.contact-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(45,106,79,.08);
    padding: 30px;
    margin-bottom: 20px;
    border-top: 4px solid #2D6A4F;
}
.contact-card h2 {
    color: #1B4332;
    font-size: 20px;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 1px dashed #d8e7df;
}
.contact-row {
    display: flex;
    align-items: flex-start;
    padding: 10px 0;
    border-bottom: 1px dashed #eaf0eb;
    font-size: 14px;
    line-height: 1.8;
}
.contact-row:last-child { border-bottom: none; }
.contact-row .label {
    flex-shrink: 0;
    width: 110px;
    color: #2D6A4F;
    font-weight: bold;
}
.contact-row .value { flex: 1; color: #444; }
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 24px;
}
.contact-grid .qr-block {
    background: #f6faf7;
    border: 1px solid #d8e7df;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
}
.contact-grid .qr-block img { width: 200px; height: 200px; margin: 0 auto; }
.contact-grid .qr-block .qr-label {
    color: #2D6A4F;
    font-weight: bold;
    margin-top: 12px;
    font-size: 14px;
}
.contact-grid .qr-block .qr-sub {
    color: #888;
    font-size: 12px;
    margin-top: 4px;
}

/* ====== 授权链展示 ====== */
.auth-chain {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 16px;
    background: #f6faf7;
    border-radius: 8px;
    margin: 12px 0;
}
.auth-chain .auth-item {
    background: #fff;
    border: 1px solid #d8e7df;
    border-radius: 4px;
    padding: 8px 16px;
    color: #1B4332;
    font-weight: bold;
    font-size: 14px;
    box-shadow: 0 1px 3px rgba(45,106,79,.08);
}
.auth-chain .arrow {
    color: #52B788;
    font-weight: bold;
    font-size: 18px;
}

/* ====== 响应式 ====== */
@media (max-width: 1006px) {
    .container, .topbar-inner, .mainnav-inner, .ticker, .footer-inner, .footer-bottom { width: 100%; padding-left: 12px; padding-right: 12px; }
    .cert-grid { grid-template-columns: repeat(2, 1fr); }
    .course-grid, .book-grid, .teacher-grid { grid-template-columns: repeat(2, 1fr); }
    .gallery-grid { grid-template-columns: repeat(2, 1fr); }
    .course-layout { grid-template-columns: 1fr; }
    .course-sidebar { position: static; }
    .contact-grid { grid-template-columns: 1fr; }
}

/* 平板：导航换行成多行，避免 9 项挤压溢出 */
@media (max-width: 768px) {
    .mainnav-inner { flex-wrap: wrap; }
    .mainnav-inner a { flex: 1 1 33.33%; min-width: 96px; padding: 12px 4px; font-size: 13px; }
    /* 首页关于我们分栏 → 单列堆叠 */
    .index-about-grid { grid-template-columns: 1fr !important; }
    .block[style*="grid-template-columns:1fr 2.2fr"] { grid-template-columns: 1fr !important; }
    .section-title { flex-wrap: wrap; }
    .book-grid, .teacher-grid, .course-grid, .cert-grid, .gallery-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-inner { flex-wrap: wrap; }
    .footer-col { flex: 1 1 45%; }
}

/* 手机：单列，进一步收紧 */
@media (max-width: 480px) {
    .mainnav-inner a { flex: 1 1 50%; min-width: 0; font-size: 12px; }
    .book-grid, .teacher-grid, .course-grid, .cert-grid, .gallery-grid { grid-template-columns: 1fr; }
    .footer-col { flex: 1 1 100%; }
    .container { padding-left: 10px; padding-right: 10px; }
    h1 { font-size: 22px; }
    .article h1 { font-size: 22px; }
    .section-title h2 { font-size: 18px; }
    .logo img { max-width: 130px; }
}