* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
    background: #f5f5f5;
    padding-bottom: 60px;
}

.page {
    display: none;
}

.page.active {
    display: block;
}

/* 头部样式 */
.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 15px;
    position: relative;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.welcome-text {
    font-size: 14px;
}

.logout-btn {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    padding: 5px 15px;
    border-radius: 15px;
    font-size: 13px;
    cursor: pointer;
}

.school-banner {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 15px;
}

.banner-img {
    width: 100%;
    height: 120px;
    background: linear-gradient(45deg, #1e3c72, #2a5298);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    font-weight: bold;
}

.school-info {
    padding: 12px 15px;
}

.school-name {
    font-size: 16px;
    color: #333;
    margin-bottom: 5px;
}

.school-address {
    font-size: 12px;
    color: #999;
    display: flex;
    align-items: center;
}

.location-icon {
    margin-right: 5px;
}

/* 我要上课按钮 */
.edu-now-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    width: 100%;
    padding: 15px;
    border-radius: 25px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.edu-now-btn .icon {
    margin-right: 8px;
    font-size: 20px;
}

/* 通用区块样式 */
.section {
    background: white;
    margin-bottom: 15px;
    padding: 15px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.section-title {
    font-size: 16px;
    color: #333;
    display: flex;
    align-items: center;
}

.section-title .icon {
    margin-right: 8px;
}

.view-all {
    color: #999;
    font-size: 14px;
    cursor: pointer;
}

/* 网格菜单 */
.grid-menu {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    padding: 10px 0;
}

.grid-item {
    text-align: center;
    cursor: pointer;
}

.grid-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    font-size: 24px;
}

.grid-label {
    font-size: 13px;
    color: #666;
}

/* 学校卡片 */
.school-card {
    display: flex;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.school-card:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.school-img {
    width: 80px;
    height: 80px;
    background: linear-gradient(45deg, #1e3c72, #2a5298);
    border-radius: 8px;
    margin-right: 12px;
    flex-shrink: 0;
}

.school-details {
    flex: 1;
}

.school-card-name {
    font-size: 16px;
    color: #333;
    margin-bottom: 5px;
}

.school-card-address {
    font-size: 12px;
    color: #999;
    margin-bottom: 5px;
}

.school-card-info {
    font-size: 12px;
    color: #666;
    margin-bottom: 3px;
}

/* 底部导航 */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    display: flex;
    justify-content: space-around;
    padding: 8px 0;
    border-top: 1px solid #eee;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
}

.nav-item {
    text-align: center;
    cursor: pointer;
    flex: 1;
}

.nav-icon {
    font-size: 22px;
    margin-bottom: 3px;
}

.nav-label {
    font-size: 11px;
    color: #666;
}

.nav-item.active .nav-icon,
.nav-item.active .nav-label {
    color: #667eea;
}

/* 后台管理样式 */
.admin-container {
    padding: 15px;
}

.admin-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 15px;
    margin: -15px -15px 15px -15px;
}

.admin-title {
    font-size: 20px;
    font-weight: bold;
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.stat-value {
    font-size: 28px;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 13px;
    color: #999;
}

/* 数据列表 */
.data-list {
    background: white;
    border-radius: 10px;
    overflow: hidden;
}

.data-item {
    padding: 15px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.data-item:last-child {
    border-bottom: none;
}

.data-info {
    flex: 1;
}

.data-title {
    font-size: 15px;
    color: #333;
    margin-bottom: 5px;
}

.data-desc {
    font-size: 12px;
    color: #999;
}

.data-actions {
    display: flex;
    gap: 8px;
}

/* 表单样式 */
.form-group {
    margin-bottom: 15px;
}

.form-label {
    display: block;
    margin-bottom: 5px;
    color: #333;
    font-size: 14px;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
}

.form-textarea {
    height: 80px;
    resize: none;
}

/* 按钮样式 */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    font-size: 14px;
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

/* 弹窗样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1001;  /* 在毛玻璃层之上 */
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 10px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    padding: 15px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-title {
    font-size: 16px;
    font-weight: bold;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
}

.modal-body {
    padding: 15px;
}

.modal-footer {
    padding: 15px;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* Toast 提示 */
.toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 15px 25px;
    border-radius: 5px;
    z-index: 2000;
    display: none;
}

.toast.active {
    display: block;
}

/* 滚动动画 */
@keyframes scroll-up {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(-100%);
    }
}
