/* 
 * 报名管理系统样式文件
 * V3设计系统
 */

/* ==================== 通用样式 ==================== */
.enrollment-page,
.class-detail-page,
.teacher-profile-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 20px;
}

.loading-container {
    text-align: center;
    padding: 100px 20px;
}

.spinner {
    width: 50px;
    height: 50px;
    margin: 0 auto 20px;
    border: 4px solid rgba(24, 144, 255, 0.2);
    border-top-color: #1890FF;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: #8C8C8C;
}

.empty-state i {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state h3 {
    margin: 16px 0 8px;
    font-size: 20px;
}

/* ==================== 页面头部 ==================== */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 32px;
}

.page-header h1 {
    font-size: 32px;
    font-weight: 700;
    margin: 0;
    color: #111827;
}

.page-header p {
    margin: 8px 0 0;
    color: #6b7280;
    font-size: 15px;
}

.user-info-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #E6F7FF;
    color: #1890FF;
    border-radius: 999px;
    font-weight: 600;
}

.guest-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    background: #FFF7E6;
    color: #FA8C16;
    border-radius: 999px;
    font-weight: 600;
}

.btn-login-link {
    padding: 4px 12px;
    background: white;
    color: #1890FF;
    border-radius: 12px;
    text-decoration: none;
    font-size: 13px;
    transition: all 0.3s;
}

.btn-login-link:hover {
    background: #1890FF;
    color: white;
}

/* ==================== 课程聚合页 ==================== */
.course-section {
    margin-bottom: 48px;
}

.subject-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 24px;
    color: #262626;
    display: flex;
    align-items: center;
    gap: 12px;
}

.subject-title i {
    color: #1890FF;
}

.course-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
}

.course-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: all 0.3s;
    border: 1px solid rgba(203, 213, 225, 0.45);
}

.course-card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    transform: translateY(-4px);
}

.course-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.course-header h3 {
    font-size: 20px;
    font-weight: 700;
    margin: 0;
    color: #262626;
}

.subject-badge {
    background: #1890FF;
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.course-desc {
    color: #595959;
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.6;
}

.class-list {
    margin-top: 20px;
}

.class-list-title {
    font-size: 14px;
    font-weight: 600;
    color: #595959;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.class-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px;
    border: 1px solid #E8E8E8;
    border-radius: 10px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.class-item:hover {
    background: #1890FF;
    color: white;
    border-color: #1890FF;
}

.class-item:hover .class-meta span {
    color: rgba(255,255,255,0.9);
}

.class-info {
    flex: 1;
}

.class-name {
    font-weight: 600;
    margin-bottom: 6px;
}

.class-meta {
    display: flex;
    gap: 16px;
    font-size: 13px;
    color: #8C8C8C;
}

.class-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.no-classes {
    text-align: center;
    padding: 20px;
    color: #BFBFBF;
    font-size: 14px;
}

/* ==================== 班级详情页 ==================== */
.sticky-header {
    position: sticky;
    top: 0;
    background: white;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    border-radius: 12px;
    margin-bottom: 24px;
}

.back-btn {
    padding: 10px 16px;
    background: #F5F5F5;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}

.back-btn:hover {
    background: #E8E8E8;
}

.enroll-btn-top {
    padding: 10px 24px;
    background: linear-gradient(135deg, #1890FF, #40a9ff);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}

.enroll-btn-top:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(24, 144, 255, 0.4);
}

.section {
    background: white;
    border-radius: 16px;
    padding: 32px;
    margin-bottom: 32px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    border: 1px solid rgba(203, 213, 225, 0.3);
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 24px;
    color: #262626;
    display: flex;
    align-items: center;
    gap: 12px;
}

.section-title i {
    color: #1890FF;
}

/* 教师卡片 */
.teacher-card {
    display: flex;
    gap: 32px;
    align-items: flex-start;
}

.teacher-avatar {
    width: 200px;
    height: 200px;
    border-radius: 16px;
    object-fit: cover;
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
    flex-shrink: 0;
}

.teacher-info {
    flex: 1;
}

.teacher-info h3 {
    font-size: 28px;
    margin: 0 0 8px 0;
    color: #111827;
}

.specialty {
    color: #1890FF;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
}

.teacher-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.teacher-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #595959;
}

.introduction {
    color: #595959;
    line-height: 1.8;
    margin-bottom: 20px;
}

.philosophy {
    background: #F0F5FF;
    padding: 20px;
    border-radius: 12px;
    border-left: 4px solid #1890FF;
    font-style: italic;
    margin: 0;
    color: #262626;
    line-height: 1.8;
}

.philosophy i {
    color: #1890FF;
    opacity: 0.5;
}

/* 全宽图片 */
.full-width-image {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.current-class-highlight {
    margin-top: 20px;
    padding: 16px 20px;
    background: linear-gradient(135deg, #FFF7E6 0%, #FFE7BA 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 15px;
    color: #874D00;
}

.current-class-highlight i {
    color: #FAAD14;
    font-size: 18px;
}

/* 课程大纲Tab */
.syllabus-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
}

.syllabus-tabs button {
    padding: 12px 24px;
    border: 2px solid #E8E8E8;
    background: white;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
    color: #595959;
}

.syllabus-tabs button.active {
    background: #1890FF;
    color: white;
    border-color: #1890FF;
}

.syllabus-tabs button:hover:not(.active) {
    border-color: #1890FF;
    color: #1890FF;
}

/* 讲次表格 */
.session-table {
    margin-bottom: 24px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #E8E8E8;
}

.session-table table {
    width: 100%;
    border-collapse: collapse;
}

.session-table th {
    background: #FAFAFA;
    padding: 14px 16px;
    text-align: left;
    font-weight: 600;
    color: #262626;
    border-bottom: 2px solid #E8E8E8;
}

.session-table td {
    padding: 14px 16px;
    border-bottom: 1px solid #F0F0F0;
}

.badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    display: inline-block;
}

.badge-success {
    background: #F6FFED;
    color: #52C41A;
}

.badge-secondary {
    background: #FAFAFA;
    color: #8C8C8C;
}

.no-sessions {
    text-align: center;
    padding: 40px 20px;
    color: #BFBFBF;
}

.no-sessions i {
    font-size: 32px;
    margin-bottom: 8px;
    opacity: 0.5;
}

/* 课程信息卡片 */
.course-info-card {
    background: linear-gradient(135deg, #F0F5FF 0%, #E6F7FF 100%);
    padding: 20px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #262626;
}

.info-item i {
    color: #1890FF;
    font-size: 18px;
    width: 24px;
    text-align: center;
}

/* 报名表单 */
.alert {
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.alert-info {
    background: #E6F7FF;
    color: #0958D9;
    border: 1px solid #91D5FF;
}

.alert a {
    color: #1890FF;
    font-weight: 600;
    text-decoration: underline;
}

.enroll-form {
    max-width: 700px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #262626;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.required {
    color: #F5222D;
}

.form-group input[type="text"],
.form-group input[type="tel"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #E8E8E8;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #1890FF;
    box-shadow: 0 0 0 3px rgba(24, 144, 255, 0.1);
}

.btn-submit {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #1890FF, #40a9ff);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(24, 144, 255, 0.4);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ==================== 教师主页 ==================== */
.profile-header {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    padding: 40px;
    background: linear-gradient(135deg, #F0F5FF 0%, #E6F7FF 100%);
    border-radius: 16px;
    margin-bottom: 32px;
}

.profile-avatar {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    border: 4px solid white;
}

.profile-info h1 {
    font-size: 36px;
    margin: 0 0 8px 0;
    color: #111827;
}

.teacher-stats {
    display: flex;
    gap: 32px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #262626;
    font-weight: 500;
}

.stat-item i {
    color: #1890FF;
    font-size: 18px;
}

.intro-text {
    color: #595959;
    line-height: 1.8;
    font-size: 15px;
}

.philosophy-quote {
    background: linear-gradient(135deg, #FFF7E6 0%, #FFE7BA 100%);
    padding: 24px;
    border-radius: 12px;
    border-left: 4px solid #FAAD14;
    font-style: italic;
    margin: 0;
    color: #262626;
    line-height: 1.8;
    font-size: 16px;
}

.philosophy-quote i {
    color: #FAAD14;
    opacity: 0.6;
}

.class-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.class-card {
    background: white;
    border: 1px solid #E8E8E8;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s;
}

.class-card:hover {
    border-color: #1890FF;
    box-shadow: 0 4px 16px rgba(24, 144, 255, 0.15);
    transform: translateY(-2px);
}

.class-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.class-card-header h3 {
    font-size: 18px;
    margin: 0;
}

.class-desc {
    color: #595959;
    font-size: 14px;
    margin-bottom: 16px;
    line-height: 1.6;
}

.btn-view {
    width: 100%;
    padding: 10px;
    background: #F5F5F5;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    color: #1890FF;
    transition: all 0.3s;
}

.btn-view:hover {
    background: #1890FF;
    color: white;
}

.coming-soon {
    text-align: center;
    padding: 60px 20px;
    color: #BFBFBF;
}

.coming-soon i {
    font-size: 48px;
    margin-bottom: 16px;
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 768px) {
    .enrollment-page,
    .class-detail-page,
    .teacher-profile-page {
        padding: 20px 16px;
    }
    
    .page-header h1 {
        font-size: 24px;
    }
    
    .course-cards {
        grid-template-columns: 1fr;
    }
    
    .teacher-card {
        flex-direction: column;
    }
    
    .teacher-avatar {
        width: 150px;
        height: 150px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .sticky-header {
        padding: 12px 16px;
    }
    
    .sticky-header h2 {
        font-size: 16px;
    }
    
    .section {
        padding: 20px;
    }
    
    .section-title {
        font-size: 20px;
    }
    
    .profile-header {
        flex-direction: column;
        padding: 24px;
    }
    
    .profile-avatar {
        width: 120px;
        height: 120px;
    }
    
    .profile-info h1 {
        font-size: 24px;
    }
    
    .teacher-stats {
        gap: 16px;
    }
    
    .class-grid {
        grid-template-columns: 1fr;
    }
}

/* ==================== 微信二维码弹窗 ==================== */
.qr-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.qr-modal-content {
    background: white;
    border-radius: 16px;
    padding: 32px;
    text-align: center;
    max-width: 360px;
    width: 90%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.qr-modal-content .close-btn {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #8C8C8C;
    line-height: 1;
}

.qr-modal-content .close-btn:hover {
    color: #262626;
}

.qr-modal-content h3 {
    margin: 0 0 12px;
    font-size: 22px;
    color: #07C160;
}

.qr-modal-content h3 i {
    margin-right: 8px;
}

.qr-modal-content .course-tip {
    color: #595959;
    margin-bottom: 20px;
    font-size: 14px;
}

.qr-modal-content .qr-image {
    width: 200px;
    height: 200px;
    object-fit: contain;
    border-radius: 8px;
    border: 1px solid #E8E8E8;
}

.qr-modal-content .qr-tip {
    margin-top: 16px;
    color: #8C8C8C;
    font-size: 13px;
    line-height: 1.6;
}

