* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
.navbar {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    color: #4A90E2;
    font-size: 1.8rem;
    font-weight: bold;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-menu a:hover {
    color: #4A90E2;
}

.login-btn {
    background: #4A90E2;
    color: #fff;
    border: none;
    padding: 0.6rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: background 0.3s;
}

.login-btn:hover {
    background: #357ABD;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.user-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: #333;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    transition: all 0.3s;
}

.user-link:hover {
    background: #f0f7ff;
    color: #4A90E2;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #4A90E2;
}

.user-name {
    font-weight: 500;
    font-size: 0.95rem;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: #333;
    border-radius: 3px;
    transition: all 0.3s;
}

/* 首页横幅 */
.hero {
    display: flex;
    align-items: center;
    padding: 4rem 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    min-height: 500px;
}

.hero-content {
    flex: 1;
    max-width: 600px;
    margin-right: 3rem;
}

.hero-content h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.hero-image {
    flex: 1;
}

.hero-image img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* 按钮样式 */
.btn {
    padding: 0.8rem 2rem;
    border-radius: 25px;
    text-decoration: none;
    display: inline-block;
    font-weight: 500;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: #fff;
    color: #667eea;
}

.btn-primary:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    color: #fff;
    border: 2px solid #fff;
}

.btn-secondary:hover {
    background: #fff;
    color: #667eea;
}

.btn-course {
    background: #4A90E2;
    color: #fff;
    width: 100%;
}

.btn-course:hover {
    background: #357ABD;
}

/* 核心服务 */
.services {
    padding: 5rem 0;
    background: #f8f9fa;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #333;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.service-card {
    background: #fff;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-icon img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin-bottom: 1rem;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #333;
}

.service-card p {
    color: #666;
    line-height: 1.8;
}

/* 课程板块 */
.courses {
    padding: 5rem 0;
}

.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.course-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.course-card:hover {
    transform: translateY(-5px);
}

.course-image img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.course-content {
    padding: 1.5rem;
}

.course-content h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.course-desc {
    color: #666;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.course-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0.5rem 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.course-duration {
    color: #666;
    font-size: 0.9rem;
}

.course-format {
    color: #4A90E2;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.2rem 0.6rem;
    background: #f0f7ff;
    border-radius: 4px;
}

.course-price {
    color: #4A90E2;
    font-size: 1.3rem;
    font-weight: bold;
}

/* 成功案例 */
.cases {
    padding: 5rem 0;
    background: #f8f9fa;
}

.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.case-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.case-card:hover {
    transform: translateY(-5px);
}

.case-image img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.case-content {
    padding: 1.5rem;
}

.case-content h3 {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
    color: #333;
}

.case-desc {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.case-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tag {
    background: #E8F4F8;
    color: #4A90E2;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.85rem;
}

/* 名师板块 */
.teachers {
    padding: 5rem 0;
}

.teachers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.teacher-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s;
}

.teacher-card:hover {
    transform: translateY(-5px);
}

.teacher-image {
    padding: 2rem 2rem 1rem;
}

.teacher-image img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid #f0f0f0;
}

.teacher-info {
    padding: 1.5rem;
}

.teacher-info h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.teacher-title {
    color: #4A90E2;
    font-weight: 500;
    margin-bottom: 1rem;
}

.teacher-desc {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.teacher-credentials {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.teacher-credentials span {
    background: #f0f0f0;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    color: #666;
}

/* 关于我们 */
.about {
    padding: 5rem 0;
    background: #f8f9fa;
}

.about-content {
    display: flex;
    align-items: center;
    gap: 3rem;
}

.about-text {
    flex: 1;
}

.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: #333;
}

.about-text p {
    color: #666;
    line-height: 1.8;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.about-stats {
    display: flex;
    gap: 3rem;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-item h3 {
    font-size: 2.5rem;
    color: #4A90E2;
    margin-bottom: 0.5rem;
}

.stat-item p {
    color: #666;
    font-size: 1rem;
}

.about-image {
    flex: 1;
}

.about-image img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* 联系我们 */
.contact {
    padding: 5rem 0;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-item h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.contact-item p {
    color: #666;
    font-size: 1.1rem;
}

.contact-form {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 10px;
}

.contact-form h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #333;
}

.contact-form form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-form input,
.contact-form textarea {
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    font-family: inherit;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: #4A90E2;
}

/* 页脚 */
.footer {
    background: #2c3e50;
    color: #fff;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: #ecf0f1;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #4A90E2;
}

.footer-section p {
    color: #ecf0f1;
    line-height: 1.8;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #34495e;
    color: #ecf0f1;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: #fff;
        flex-direction: column;
        padding: 1rem;
        box-shadow: 0 5px 10px rgba(0,0,0,0.1);
    }

    .nav-menu.active {
        display: flex;
    }

    .hero {
        flex-direction: column;
        text-align: center;
    }

    .hero-content {
        margin-right: 0;
        margin-bottom: 2rem;
    }

    .hero-content h2 {
        font-size: 2rem;
    }

    .about-content {
        flex-direction: column;
    }

    .contact-content {
        grid-template-columns: 1fr;
    }

    .about-stats {
        justify-content: space-around;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
}

/* 登录/注册页面 */
.auth-section {
    padding: 4rem 0;
    background: #f8f9fa;
    min-height: 70vh;
}

.auth-card {
    max-width: 720px;
    margin: 0 auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    overflow: hidden;
}

.auth-tabs {
    display: flex;
    gap: 0.5rem;
    padding: 1rem;
    background: #fff;
    border-bottom: 1px solid #eee;
}

.auth-tab {
    flex: 1;
    padding: 0.9rem 1rem;
    background: #f2f4f8;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    color: #333;
}

.auth-tab.active {
    background: #4A90E2;
    color: #fff;
}

.auth-panel {
    display: none;
    padding: 2rem;
}

.auth-panel.active {
    display: block;
}

.login-switch {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.login-mode-btn {
    flex: 1;
    padding: 0.6rem 0.8rem;
    border: 1px solid #e5e7eb;
    background: #fafafa;
    border-radius: 8px;
    cursor: pointer;
}

.login-mode-btn.active {
    background: #E8F4F8;
    border-color: #b9e3f3;
    color: #2378a6;
}

.form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-row {
    display: flex;
    gap: 0.75rem;
}

.form-row input {
    flex: 1;
    padding: 0.9rem 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
}

.form-row input:focus {
    outline: none;
    border-color: #4A90E2;
    box-shadow: 0 0 0 3px rgba(74,144,226,0.15);
}

.form-row-code input {
    flex: 1;
}

.btn-code {
    white-space: nowrap;
    border-radius: 8px;
    background: #4A90E2;
    color: #fff;
    border: none;
    padding: 0 1rem;
}

.btn-code:disabled {
    background: #9bbfe9;
    cursor: not-allowed;
}

.btn-submit {
    margin-top: 0.5rem;
}

.hidden { display: none; }

.captcha-row {
    align-items: center;
}

.captcha-box {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
}

.captcha-box #captchaQuestion {
    display: inline-block;
    padding: 0.5rem 0.75rem;
    background: #f2f4f8;
    border-radius: 6px;
    color: #333;
    font-weight: 600;
}

.agree-row label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #666;
}

@media (max-width: 768px) {
    .auth-card { margin: 0 1rem; }
    .form-row { flex-direction: column; }
    .btn-code { padding: 0.8rem 1rem; }
}
