/* 基础样式 */

:root {
    --primary-color: #c7000b;
    --secondary-color: #ffcb05;
    --text-color: #333;
    --light-text: #fff;
    --border-color: #e0e0e0;
    --bg-light: #f5f5f5;
    --bg-dark: #b71c1c;
}

body {
    font-family: "Microsoft YaHei", "SimSun", sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--bg-light);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* 顶部导航栏 */
.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    background-color: #fff;
}

/* 主导航栏 */
.main-header {
    background: url("https://cee.hutb.edu.cn/r/cms/jsjxy/default/images/header.jpg") no-repeat center center;
    background-size: cover;
    color: var(--light-text);
    padding: 15px 0;
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

 main {
    background-color: #fff;
    flex: 1;
}

.logo-container {
    display: flex;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 50px;
    margin-right: 15px;
}

.logo-text {
    font-size: 1.2rem;
    font-weight: bold;
    color: #9E020B;
}

.detail-info {
    color: #9E020B;
    font-size: 1.2rem;
    margin-left: 10px;
    font-weight: bold;
}

/* 修改导航菜单样式 */
.nav {
    margin-left: auto;
}

.nav ul {
    display: flex;
}

.nav li {
    margin-left: 30px;
    position: relative;
}

.nav li a {
    padding: 10px 0;
    font-size: 1.1rem;
    transition: color 0.3s;
    color: #9E020B;
}

.nav li a:hover {
    color: #9E020B;
}

.nav li.active a {
    color: #9E020B;
    font-weight: bold;
}

.nav li.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: #9E020B;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--light-text);
    margin: 2px 0;
    transition: all 0.3s;
}

/* 轮播图 */
.banner {
    margin-bottom: 20px;
    background-image: url('../images/banner-bg.jpg');
}

.banner .container {
    padding: 0;
}

.swiper {
    width: 100%;
    height: 400px;
    max-width: 1200px;
    margin: 0 auto;
}

.swiper-slide {
    position: relative;
}

.swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.5);
    color: var(--light-text);
    padding: 15px;
}

.slide-caption h2 {
    font-size: 1.5rem;
    margin: 0;
}

.swiper-button-prev,
.swiper-button-next {
    color: var(--light-text);
}

.swiper-pagination-bullet-active {
    background-color: var(--primary-color);
}

/* 公告栏 */
.notice-section {
    background-color: #fff;
    padding: 20px 0;
    margin-bottom: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
}

.section-header h2 {
    font-size: 1.3rem;
    color: var(--primary-color);
    position: relative;
    padding-left: 15px;
}

.section-header h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 5px;
    height: 20px;
    background-color: var(--primary-color);
}

.more-btn {
    color: #666;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.more-btn:hover {
    color: var(--primary-color);
}

.notice-list {
    padding: 0 10px;
}

.notice-item {
    display: flex;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px dashed var(--border-color);
}

.notice-date {
    color: #888;
    font-size: 0.9rem;
    margin-right: 15px;
    flex-shrink: 0;
}

.notice-title {
    flex-grow: 1;
    transition: color 0.3s;
}

.notice-title:hover {
    color: var(--primary-color);
}

/* 学习进度和党员身份 */
.info-section {
    padding: 20px 0;
    margin-bottom: 30px;
}

.info-wrapper {
    display: flex;
    gap: 20px;
}

.study-progress, .party-status {
    background-color: #fff;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    padding: 20px;
}

.study-progress {
    flex: 2;
}

.party-status {
    flex: 1;
}

.progress-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
}

.progress-number {
    font-size: 2rem;
    font-weight: bold;
    color: #333;
}

.progress-number .current {
    color: var(--primary-color);
}

.progress-circle {
    width: 150px;
    height: 150px;
    position: relative;
}

.circle-wrapper {
    width: 100%;
    height: 100%;
    position: relative;
}

.circle-wrapper svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.progress-text .label {
    display: block;
    font-size: 0.9rem;
    color: #666;
}

.progress-text .value {
    display: block;
    font-size: 1.5rem;
    font-weight: bold;
    color: #333;
}

.status-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 0;
}

.status-title {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary-color);
}

.status-subtitle {
    font-size: 1.5rem;
    margin-top: 10px;
}

/* 底部导航栏 */
.footer {
    background-image: url('../images/footer.jpg');
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    color: #fff;
    position: relative;
}


/* 友情链接部分 */
.footer-links {
    padding: 15px 0;
    position: relative;
    z-index: 2;
}

.links-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.links-title {
    font-weight: bold;
    color: #D7C1C1;
    margin-right: 10px;
    white-space: nowrap;
    display: inline-block;
    line-height: 1.6;
    padding: 0;
    margin-bottom: 5px;
}

.links-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.links-list a {
    color: #D7C1C1;
    margin: 0 10px 5px;
    transition: opacity 0.3s;
    display: inline-block;
    line-height: 1.6;
    padding: 0;
}

.links-list a:hover {
    opacity: 0.8;
}

/* 底部信息部分 */
.footer-info {
    padding: 30px 0;
    position: relative;
    z-index: 2;
}

.copyright {
    text-align: center;
    width: 100%;
    padding: 20px 0;
    font-size: 0.9rem;
    line-height: 1.8;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .logo img {
        height: 40px;
    }
    
    .logo-text, .detail-info {
        font-size: 1.1rem;
    }
    
    .info-wrapper {
        flex-direction: column;
    }
    
    .study-progress, .party-status {
        width: 100%;
    }
    
    .swiper {
        height: 300px;
    }
    
    .left-info {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .footer-logo {
        margin-bottom: 20px;
    }
}

@media (max-width: 768px) {
    .main-header .container {
        flex-wrap: wrap;
    }
    
    .logo-container {
        width: 80%;
    }
    
    .logo-text, .detail-info {
        font-size: 1rem;
    }
    
    .logo img {
        height: 35px;
    }
    
    .menu-toggle {
        display: flex;
        width: 20%;
        justify-content: flex-end;
    }
    
    .nav {
        width: 100%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s;
    }
    
    .nav.active {
        max-height: 300px;
    }
    
    .nav ul {
        flex-direction: column;
        padding: 10px 0;
    }
    
    .nav li {
        margin: 0;
        padding: 10px 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .nav li.active::after {
        display: none;
    }
    
    .swiper {
        height: 250px;
    }
    
    .slide-caption h2 {
        font-size: 1.2rem;
    }
    
    .progress-content {
        flex-direction: column;
        gap: 20px;
    }
    
    .info-wrapper {
        flex-direction: column;
        text-align: center;
    }
    
    .left-info {
        flex-direction: column;
        align-items: center;
    }
    
    .footer-logo {
        flex-direction: column;
        text-align: center;
        margin-right: 0;
        margin-bottom: 20px;
    }
    
    .footer-logo img {
        margin-right: 0;
        margin-bottom: 10px;
    }
    
    .qrcode-container {
        margin-bottom: 20px;
    }
    
    /* 文章详情页移动端适配 */
    .article-footer {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .article-share {
        margin-top: 15px;
    }
    
    .article-meta {
        flex-direction: column;
        align-items: center;
    }
    
    .article-meta span {
        margin: 5px 0;
    }
    
    /* 政策文件和学习资料移动端适配 */
    .document-item {
        flex-direction: column;
        padding: 10px;
    }
    
    .document-icon {
        margin-bottom: 10px;
    }
    
    .material-grid {
        grid-template-columns: 1fr;
    }
    
    .material-item {
        margin-bottom: 15px;
    }
}

@media (max-width: 576px) {
    .logo-text, .detail-info {
        font-size: 0.9rem;
    }
    
    .logo img {
        height: 30px;
        margin-right: 8px;
    }
    
    .detail-info {
        margin-left: 5px;
    }
    
    .swiper {
        height: 200px;
    }
    
    .notice-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .notice-date {
        margin-bottom: 5px;
    }
    
    .links-wrapper {
        flex-direction: column;
        align-items: center;
    }
    
    .links-title {
        margin-bottom: 10px;
        margin-right: 0;
    }
    
    .qrcode-container {
        flex-direction: column;
    }
    
    .qrcode-item {
        margin-right: 0;
        margin-bottom: 15px;
    }
}

/* 确保容器内容在遮罩上方 */
.footer .container {
    position: relative;
    z-index: 2;
}

/* 理论学习页面样式 */
.page-header {
    margin: 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #9E020B;
}

.page-header h1 {
    color: #9E020B;
    font-size: 1.8rem;
    font-weight: bold;
}

.policy-documents, .study-materials {
    margin-bottom: 30px;
    background-color: #fff;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 20px;
}

.section-header {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
}

.section-header h2 {
    font-size: 1.5rem;
    color: #333;
    position: relative;
    padding-left: 15px;
    font-weight: bold;
}

.section-header h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 5px;
    height: 80%;
    background-color: #9E020B;
    border-radius: 2px;
}

.document-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.document-item {
    display: flex;
    align-items: flex-start;
    padding: 10px 0;
    border-bottom: 1px dashed #e0e0e0;
    position: relative;
}

.document-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    margin-right: 10px;
    background-color: #9E020B;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.document-content {
    flex-grow: 1;
}

.document-content a {
    color: #333;
    line-height: 1.6;
    transition: color 0.3s;
    font-size: 16px;
    font-weight: bold;
}

.document-content .publish-info {
    font-size: 14px;
    color: #666;
    font-weight: normal;
    margin-top: 5px;
}

.document-content a:hover {
    color: #9E020B;
}

.material-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.material-item {
    display: flex;
    align-items: flex-start;
    padding: 10px 0;
    border-bottom: 1px dashed #e0e0e0;
    position: relative;
}

.material-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    margin-right: 10px;
    background-color: #9E020B;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.material-content {
    flex-grow: 1;
}

.material-content a {
    color: #333;
    line-height: 1.6;
    transition: color 0.3s;
    font-size: 16px;
    font-weight: bold;
}

.material-content .publish-info {
    font-size: 14px;
    color: #666;
    font-weight: normal;
    margin-top: 5px;
}

.material-content a:hover {
    color: #9E020B;
}

/* 已学习标记样式 */
.document-learned {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-color: #4CAF50;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.3s;
}

.document-learned::before {
    content: '✓';
    font-weight: bold;
}

.document-item.learned .document-learned,
.material-item.learned .document-learned {
    opacity: 1;
}

.document-item.learned .document-content a,
.material-item.learned .material-content a {
    color: #666;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .page-header h1 {
        font-size: 1.5rem;
    }
    
    .section-header h2 {
        font-size: 1.3rem;
    }
    
    .policy-documents, .study-materials {
        padding: 15px;
    }
}

@media (max-width: 576px) {
    .page-header {
        margin: 15px 0;
    }
    
    .page-header h1 {
        font-size: 1.3rem;
    }
    
    .section-header h2 {
        font-size: 1.1rem;
    }
    
    .document-item {
        padding: 8px 0;
    }
    
    .document-content a {
        font-size: 0.9rem;
    }
}