/* styles.css */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f9f9f9;
    color: #333;
}

/* 导航栏样式 */
.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #0074D9;
    padding: 15px 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.logo {
    display: flex;
    align-items: center;
    font-size: 26px;
    font-weight: bold;
    color: white;
}

.logo-container {
    display: flex;
    align-items: center;
    margin-right: 20px;
}

.site-logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 10px;
    border: 2px solid #3498db;
    transition: transform 0.3s ease;
}

.site-logo:hover {
    transform: scale(1.1);
}

.logo-text {
    font-size: 1.5em;
    font-weight: bold;
    color: #2c3e50;
    text-decoration: none;
}

.nav-links {
    display: flex;
    align-items: center;
    margin-left: auto;
    list-style: none;
    gap: 25px;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-size: 16px;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #FFC107;
}

.search {
    display: flex;
    gap: 10px;
}

.search input {
    padding: 8px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
}

.search button {
    padding: 8px 16px;
    background-color: #FFC107;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

.search button:hover {
    background-color: #e0a800;
}

.login a {
    color: white;
    text-decoration: none;
    margin: 0 5px;
    font-size: 14px;
    transition: color 0.3s ease;
}

.login a:hover {
    color: #FFC107;
}

/* 登录/注册表单样式 */
.auth-form {
    max-width: 400px;
    width: 90%; /* 在移动设备上留出边距 */
    margin: 0 auto; /* 水平居中 */
    padding: 30px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); /* 更柔和的阴影 */
    text-align: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%); /* 垂直和水平居中 */
}

.auth-form h2 {
    margin-bottom: 20px;
    color: #0074D9;
    font-size: 24px;
}

.form-group {
    margin-bottom: 20px;
    text-align: left; /* 输入框标签左对齐 */
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.form-group input:focus {
    border-color: #0074D9; /* 输入框聚焦时边框颜色变化 */
    outline: none;
}

.auth-form button {
    width: 100%;
    padding: 12px;
    background-color: #0074D9;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.auth-form button:hover {
    background-color: #005bb5; /* 按钮悬停时颜色变深 */
}

.auth-form p {
    margin-top: 20px;
    font-size: 14px;
    color: #666;
}

.auth-form a {
    color: #0074D9;
    text-decoration: none;
    transition: color 0.3s ease;
}

.auth-form a:hover {
    color: #005bb5; /* 链接悬停时颜色变深 */
    text-decoration: underline;
}

/* 响应式设计 */
@media (max-width: 480px) {
    .auth-form {
        padding: 20px;
    }

    .auth-form h2 {
        font-size: 20px;
    }

    .form-group input {
        padding: 8px;
    }

    .auth-form button {
        padding: 10px;
    }
}


/* 轮播图样式 */
.carousel {
    position: relative;
    width: 100%;
    max-width: 900px; /* 设置最大宽度 */
    height: 350px; /* 明确高度以包含图片 */
    margin: 30px auto;
    overflow: hidden;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); /* 添加柔和阴影 */
}
.carousel-inner {
    white-space: nowrap; /* 防止内部元素换行 */
    transition: transform 0.5s ease-in-out; /* 平滑过渡效果 */
    height: 100%; /* 占据轮播图容器的全部高度 */
    font-size: 0; /* 消除inline-block元素间的空白 */
}
.carousel-item {
    display: inline-block; /* 水平排列 */
    vertical-align: top; /* 对齐顶部 */
    width: 100%; /* 每个轮播项占据100%宽度 */
    height: 100%; /* 每个轮播项占据100%高度 */
    box-sizing: border-box;
    text-align: center;
    position: relative;
}
.carousel-item img {
    width: 100%;
    height: 100%; /* 让图片填充轮播项的高度 */
    object-fit: cover; /* 保持图片比例，覆盖容器 */
    border-radius: 10px; /* 圆角 */
}
.carousel-caption {
    position: absolute;
    left: 0; right: 0; bottom: 20px;
    color: #fff;
    background: rgba(0,0,0,0.4);
    padding: 10px 0;
    font-size: 1.2em;
    border-radius: 0 0 10px 10px;
}
.carousel-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2em;
    color: #333;
    background: rgba(255,255,255,0.7);
    border-radius: 50%;
    width: 40px; height: 40px;
    text-align: center;
    line-height: 40px;
    cursor: pointer;
    z-index: 2;
    user-select: none;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); /* 按钮阴影 */
    transition: background-color 0.3s ease; /* 鼠标悬停过渡 */
}
.carousel-control:hover {
    background-color: rgba(255,255,255,0.9);
}
.carousel-control.prev { left: 10px; }
.carousel-control.next { right: 10px; }

/* 系统公告样式 */
.announcements {
    max-width: 900px;
    margin: 30px auto;
    padding: 20px;
    background: #e9f5ff;
    border-left: 5px solid #0074D9;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.announcements h2 {
    color: #0074D9;
    font-size: 1.8em;
    margin-bottom: 15px;
    border-bottom: 1px solid #cceeff;
    padding-bottom: 10px;
}

.announcement-list {
    max-height: 150px; /* 设置最大高度 */
    overflow-y: auto; /* 垂直滚动 */
    padding-right: 10px; /* 避免滚动条覆盖内容 */
}

.announcement-list p {
    color: #555;
    font-style: italic;
}

.announcement-item {
    background: #f0f8ff;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 5px;
    border: 1px solid #cfe6f7;
    transition: all 0.3s ease;
}

.announcement-item:hover {
    background-color: #e0f2ff;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

.announcement-item h3 {
    color: #005bb5;
    font-size: 1.1em;
    margin-top: 0;
    margin-bottom: 5px;
}

.announcement-item p {
    color: #333;
    line-height: 1.6;
    margin-bottom: 0;
}

.featured-courses h2 {
    font-size: 28px;
    color: #0074D9;
    text-align: center;
    margin-bottom: 30px;
}

.course-list {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.course-card {
    background-color: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    width: 280px;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.course-card img {
    width: 50%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 15px;
}

.course-card h3 {
    font-size: 20px;
    color: #333;
    margin: 10px 0;
}

.course-card p {
    font-size: 14px;
    color: #666;
    margin: 10px 0;
}

.course-card a {
    display: inline-block;
    margin-top: 10px;
    padding: 8px 16px;
    background-color: #0074D9;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.course-card a:hover {
    background-color: #0074D9;
}

/* 页脚样式 */
.footer {
    background-color: #333;
    color: white;
    text-align: center;
    padding: 20px;
    margin-top: 40px;
}

.footer p {
    margin: 0;
	font-size: 14px;}

/* 学习资料内容 */
.materials {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.materials h2 {
    text-align: center;
    font-size: 28px;
    color: #0074D9;
    margin-bottom: 20px;
}

.filter {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

.filter button {
    padding: 8px 16px;
    background-color: #e0e0e0;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

.filter button.active,
.filter button:hover {
    background-color: #0074D9;
    color: white;
}

.material-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.material-card {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.material-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.material-icon {
    font-size: 40px;
    color: #0074D9;
    margin-bottom: 10px;
}

.material-card h3 {
    font-size: 20px;
    color: #333;
    margin: 10px 0;
}

.material-card p {
    font-size: 14px;
    color: #666;
    margin: 10px 0;
}

.download-btn {
    display: inline-block;
    margin-top: 10px;
    padding: 8px 16px;
    background-color: #0074D9;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.download-btn:hover {
    background-color: #0074D9;
}

	
	/* 个人中心样式 */
.profile {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.profile-info {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 30px;
}

.avatar img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
}

.details h3 {
    margin: 0;
    font-size: 24px;
    color: #333;
}

.details p {
    margin: 5px 0;
    color: #666;
}

.details a {
    display: inline-block;
    margin-top: 10px;
    padding: 8px 16px;
    background-color: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.details a:hover {
    background-color: #45a049;
}

.activity {
    background-color: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.activity h3 {
    margin-top: 0;
    font-size: 20px;
    color: #333;
}

.activity ul {
    list-style: none;
    padding: 0;
}

.activity li {
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
}

.activity li:last-child {
    border-bottom: none;}

/* 背景容器 */
.auth-container {
    background: rgba(255, 255, 255, 0.9);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

/* 社区页面布局 */
.community-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
    display: flex;
    gap: 20px;
}

/* 话题侧边栏 */
.topics-sidebar {
    width: 250px;
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    height: fit-content;
}

.topics-sidebar h3 {
    margin-bottom: 15px;
    color: #333;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.topics-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.topic-item {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.topic-item:hover {
    background-color: #f5f5f5;
}

.topic-item.active {
    background-color: #e8f5e9;
    color: #4CAF50;
}

.topic-item i {
    margin-right: 10px;
    font-size: 18px;
    width: 20px;
    text-align: center;
}

/* 主要内容区 */
.main-content {
    flex: 1;
}

/* 发帖表单 */
.post-form {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.post-form h3 {
    margin-bottom: 15px;
    color: #333;
}

.post-form .form-group {
    margin-bottom: 15px;
}

.post-form label {
    display: block;
    margin-bottom: 5px;
    color: #666;
}

.post-form select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background-color: #fff;
}

.post-form input,
.post-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.post-form textarea {
    height: 100px;
    resize: vertical;
}

.post-form button {
    background: #4CAF50;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.post-form button:hover {
    background: #45a049;
}

/* 帖子卡片 */
.post-card {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.post-card h3 {
    margin: 0 0 10px 0;
    color: #333;
}

.post-card .topic-tag {
    display: inline-block;
    padding: 4px 8px;
    background: #e8f5e9;
    color: #4CAF50;
    border-radius: 4px;
    font-size: 12px;
    margin-bottom: 10px;
}

.post-card p {
    color: #666;
    margin-bottom: 15px;
}

.post-meta {
    font-size: 12px;
    color: #888;
    margin-bottom: 10px;
}

.post-meta span {
    margin-right: 15px;
}

.post-actions {
    display: flex;
    gap: 15px;
}

.post-actions button {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
}

.post-actions button:hover {
    color: #4CAF50;
}

/* 评论模态框 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
}

.modal-content {
    background: #fff;
    width: 90%;
    max-width: 600px;
    margin: 50px auto;
    padding: 20px;
    border-radius: 8px;
    position: relative;
}

.close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}

.comments-list {
    max-height: 300px;
    overflow-y: auto;
    margin: 20px 0;
}

.comment {
    padding: 10px;
    border-bottom: 1px solid #eee;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.comment .username {
    font-weight: bold;
    color: #333;
}

.comment .time {
    color: #888;
    font-size: 12px;
}

#commentForm textarea {
    width: 100%;
    height: 80px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 10px;
    resize: vertical;
}

#commentForm button {
    background: #4CAF50;
    color: white;
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

#commentForm button:hover {
    background: #45a049;
}

/* 个人中心页面样式 */
.profile-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
}

.profile-header {
    background: #fff;
    border-radius: 10px;
    padding: 30px;
    display: flex;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.profile-avatar {
    position: relative;
    width: 120px;
    height: 120px;
    background: #f0f2f5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 30px;
    overflow: hidden;
}

.avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-upload-form {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.5);
    padding: 5px;
    text-align: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.profile-avatar:hover .avatar-upload-form {
    opacity: 1;
}

.avatar-upload-label {
    color: #fff;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.avatar-upload-label i {
    font-size: 16px;
}

.profile-info {
    flex: 1;
}

.profile-info h2 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 24px;
}

.profile-info p {
    margin: 8px 0;
    color: #666;
    font-size: 16px;
}

.profile-info i {
    width: 20px;
    color: #4a90e2;
    margin-right: 10px;
}

.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: #fff;
    border-radius: 10px;
    padding: 20px;
    display: flex;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-card i {
    font-size: 40px;
    color: #4a90e2;
    margin-right: 20px;
}

.stat-info h3 {
    margin: 0;
    color: #666;
    font-size: 16px;
}

.stat-info p {
    margin: 5px 0 0 0;
    color: #333;
    font-size: 24px;
    font-weight: bold;
}

.profile-content {
    background: #fff;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.content-section {
    margin-bottom: 30px;
}

.content-section:last-child {
    margin-bottom: 0;
}

.content-section h3 {
    color: #333;
    font-size: 20px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f2f5;
}

.content-section h3 i {
    color: #4a90e2;
    margin-right: 10px;
}

.post-list {
    display: grid;
    gap: 15px;
}

.post-item {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    transition: background-color 0.3s ease;
}

.post-item:hover {
    background: #f0f2f5;
}

.post-item h4 {
    margin: 0 0 10px 0;
}

.post-item h4 a {
    color: #333;
    text-decoration: none;
}

.post-item h4 a:hover {
    color: #4a90e2;
}

.post-meta {
    display: flex;
    gap: 15px;
    color: #666;
    font-size: 14px;
}

.post-meta span {
    display: flex;
    align-items: center;
}

.post-meta i {
    margin-right: 5px;
    color: #4a90e2;
}

.no-content {
    color: #666;
    text-align: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .profile-header {
        flex-direction: column;
        text-align: center;
    }

    .profile-avatar {
        margin: 0 0 20px 0;
    }

    .stats-container {
        grid-template-columns: 1fr;
    }

    .post-meta {
        flex-direction: column;
        gap: 5px;
    }
}

/* 课程资料页面样式 */
.materials-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 30px;
}

.categories-sidebar {
    background: #fff;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    height: fit-content;
}

.categories-sidebar h3 {
    color: #333;
    margin: 0 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f2f5;
}

.categories-sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.categories-sidebar li {
    margin-bottom: 10px;
}

.categories-sidebar li:last-child {
    margin-bottom: 0;
}

.categories-sidebar a {
    display: block;
    padding: 10px;
    color: #666;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.categories-sidebar a:hover {
    background: #f0f2f5;
    color: #4a90e2;
}

.categories-sidebar li.active a {
    background: #4a90e2;
    color: #fff;
}

.main-content {
    background: #fff;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.sort-options {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f2f5;
}

.sort-options a {
    color: #666;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.sort-options a:hover {
    background: #f0f2f5;
    color: #4a90e2;
}

.sort-options a.active {
    background: #4a90e2;
    color: #fff;
}

.material-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.material-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.material-card:hover {
    transform: translateY(-5px);
}

.material-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.material-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.material-icon {
    width: 100%;
    height: 200px;
    background: #f0f2f5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.material-icon i {
    font-size: 80px;
    color: #666;
}

.material-info {
    padding: 20px;
}

.material-category {
    display: inline-block;
    padding: 5px 10px;
    background: #f0f2f5;
    color: #666;
    border-radius: 15px;
    font-size: 14px;
    margin-bottom: 10px;
}

.material-info h3 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 18px;
}

.material-info .description {
    color: #666;
    margin: 0 0 15px 0;
    font-size: 14px;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.material-meta {
    display: flex;
    gap: 15px;
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
}

.material-meta span {
    display: flex;
    align-items: center;
}

.material-meta i {
    margin-right: 5px;
    color: #4a90e2;
}

.download-btn {
    display: inline-block;
    padding: 8px 15px;
    background: #4a90e2;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.download-btn:hover {
    background: #357abd;
}

.download-btn i {
    margin-left: 5px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .materials-container {
        grid-template-columns: 1fr;
    }

    .categories-sidebar {
        margin-bottom: 20px;
    }

    .sort-options {
        flex-wrap: wrap;
    }

    .material-grid {
        grid-template-columns: 1fr;
    }
}

/* 消息提示样式 */
.message {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
    text-align: center;
}

.success-message {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.error-messages {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.error {
    margin: 5px 0;
}
