/* 页面通用样式 */


/* body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
} */

header {
    background-color: #333;
    color: #fff;
    padding: 10px 0;
}

header nav ul {
    list-style: none;
    padding: 0;
    text-align: center;
}

header nav ul li {
    display: inline;
    margin: 0 15px;
}

header nav ul li a {
    color: #fff;
    text-decoration: none;
}

main {
    padding: 20px;
    max-width: 1200px;
    margin: auto;
}

h1 {
    text-align: left;
    margin-bottom: 5px;
}

.page {
    width: 83%;
    float: left;
    margin-right: 0;
    padding-left: 4.2372881356%;
    padding-right: 0%;
}

.page-full {
    width: 100%;
    float: left;
    margin-right: 0;
    padding-left: 4.2372881356%;
    padding-right: 0%;
}

a {
    color: #000 !important;
    /* 黑色 */
}

a:hover {
    color: #40E0D0;
    /* 鼠标悬停时也是黑色 */
}


/* 卡片容器 */

.card-container {
    display: flex;
    flex-direction: column;
    /* 将卡片容器改为纵向布局 */
    gap: 3px;
    /* 卡片之间的间距 */
    justify-content: space-between;
    /* 保持卡片之间的空白 */
    width: 100%;
    max-width: 100%;
}


/* 单个卡片样式 */

.card {
    background-color: #fff;
    border-radius: 2px;
    border: 1px solid transparent;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
    padding: 20px;
    display: flex;
    align-items: stretch;
    gap: 20px;
    max-width: 100%;
    /* 卡片占据整个容器的宽度 */
    flex-direction: row;
    /* 让卡片内部的内容横向排列 */
    box-sizing: border-box;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.card-image {
    width: 300px;
    flex-shrink: 0;
    display: flex;
    align-items: stretch;
    align-self: stretch;
}

.card:hover {
    border-color: #ddd;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
}

.card-container-aboutme {
    display: flex;
    flex-direction: column;
    /* 将卡片容器改为纵向布局 */
    gap: 3px;
    /* 卡片之间的间距 */
    justify-content: space-between;
    /* 保持卡片之间的空白 */
    width: 100%;
    max-width: 100%;
}

.card-aboutme {
    transform: scale(0.9);
    transform-origin: top left;
    background-color: #fff;
    border-radius: 2px;
    border: 1px solid transparent;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
    padding: 5px;
    display: flex;
    align-items: stretch;
    gap: 20px;
    max-width: 100%;
    /* 卡片占据整个容器的宽度 */
    flex-direction: row;
    /* 让卡片内部的内容横向排列 */
    box-sizing: border-box;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.card-aboutme .card-image {
    width: 300px;
    flex-shrink: 0;
    display: flex;
    align-items: stretch;
    align-self: stretch;
}

.card-aboutme:hover {
    border-color: #ddd;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
}

/* 首页about页面卡片图片样式 */
.card-aboutme img {
    width: 100%;
    height: 100%;
    border-radius: 0px;
    object-fit: cover;
    flex-shrink: 0;
    display: block;
}


/* 图片样式 */

.card img {
    width: 100%;
    /* 图片宽度充满容器 */
    height: 100%;
    /* 充满左侧栏高度 */
    border-radius: 0px;
    object-fit: cover;
    flex-shrink: 0;
    display: block;
}


/* 卡片内文字部分 */

.card .card-text {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    flex-grow: 1;
    padding-bottom: 10px;
}


/* 卡片标题 */

.card h2 {
    font-size: 1.5em;
    margin-bottom: 15px;
    color: #333;
}


/* 卡片正文 */

.card p {
    margin: 10px 0;
}


/* 按钮样式 */

.card .btn {
    display: inline-block;
    background-color: #fff;
    /* 设置按钮背景为白色 */
    color: #333 !important;
    /* 按钮文字颜色 */
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 1px;
    text-align: center;
    margin-top: auto;
    border: 1px solid #ccc !important;
    /* 浅灰色边框 */
    transition: background-color 0.3s, color 0.3s;
}


/* 按钮悬停时的样式 */

.card .btn:hover {
    background-color: #f0f0f0 !important;
    /* 悬停时背景变为浅灰色 */
    border-color: #bbb !important;
    /* 边框变得稍深一些 */
    color: #000 !important;
    /* 悬停时文本颜色变为黑色 */
    text-decoration: none;
}

.card-aboutme .btn {
    display: inline-block;
    background-color: #fff;
    /* 设置按钮背景为白色 */
    color: #333 !important;
    /* 按钮文字颜色 */
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 1px;
    text-align: center;
    margin-top: auto;
    border: 1px solid #ccc !important;
    /* 浅灰色边框 */
    transition: background-color 0.3s, color 0.3s;
}


/* 按钮悬停时的样式 */

.card-aboutme .btn:hover {
    background-color: #f0f0f0 !important;
    /* 悬停时背景变为浅灰色 */
    border-color: #bbb !important;
    /* 边框变得稍深一些 */
    color: #000 !important;
    /* 悬停时文本颜色变为黑色 */
    text-decoration: underline;
}

.projects_container {
    display: flex;
    flex-wrap: wrap;
    gap: 50px;
}

.projects_container_aboutme {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.projcard_card {
    position: relative;
    width: 300px;
    height: 300px;
    background-color: #fff;
    border-radius: 0px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.projcard_card_aboutme {
    transform: scale(0.95);
    transform-origin: top left;
    position: relative;
    width: 300px;
    height: 300px;
    background-color: #fff;
    border-radius: 0px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.projcard_image {
    position: relative;
    border-radius: 0px;
    height: 100%;
    width: 100%;
    overflow: hidden;
}

.projcard_image img {
    display: block;
    width: 100%;
    height: 100%;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    /* Semi-transparent black overlay */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 20px;
    color: white;
    opacity: 0;
    /* Initially hidden */
    transition: 0.3s ease;
    /* Smooth transition */
    z-index: 10;
}

.projcard_image:hover .overlay {
    opacity: 1 !important;
    /* Show the overlay on hover */
}

.projcard_content {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
}

.projcard_header {
    display: flex;
    justify-content: space-between;
}

.projcard_header h2 {
    font-size: 20px;
    margin: 0;
    color: white;
}

.projcard_header .date {
    font-size: 14px;
    color: white;
}

.projcard_footer {
    align-self: flex-start;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    max-width: 100%;
}

.projcard_footer .tag {
    font-size: 11px;
    color: white;
    background-color: rgba(255, 255, 255, 0.3);
    /* Semi-transparent white background for the tag */
    padding: 4px 8px;
    border-radius: 15px;
    white-space: nowrap;
    flex-shrink: 1;
    min-width: fit-content;
}


/* 响应式设计：在小屏幕下保持布局 */

/* 针对普通卡片（publications页面）的响应式设计 */
@media (max-width: 768px) {
    .card {
        flex-direction: column;
        /* 当屏幕变小时，卡片内的内容变为纵向排列 */
        align-items: center;
        padding: 15px;
    }
    .card-image {
        width: 100%;
        max-width: 300px;
    }
    .card img {
        width: 100%;
        height: 200px;
    }
    .card .card-text {
        text-align: center;
    }
    .card-icons {
        position: static;
        justify-content: center;
        margin-top: 15px;
        flex-wrap: wrap;
    }
}

/* 针对首页about页面的卡片响应式设计 */
@media (max-width: 768px) {
    .card-aboutme {
        flex-direction: column;
        align-items: center;
        padding: 15px;
        transform: none; /* 在小屏幕上取消缩放 */
    }
    .card-aboutme .card-image {
        width: 100%;
        max-width: 300px;
    }
    .card-aboutme img {
        width: 100%;
        height: 200px;
    }
    .card-aboutme .card-text {
        text-align: center;
    }
    .card-aboutme .card-icons {
        position: static;
        justify-content: center;
        margin-top: 15px;
        flex-wrap: wrap;
    }
}

/* 针对中等屏幕的优化 */
@media (max-width: 1024px) and (min-width: 769px) {
    .card-aboutme {
        transform: scale(0.95);
    }
    .card-aboutme img {
        width: 200px;
    }
}

/* 针对大屏幕的优化 */
@media (min-width: 1200px) {
    .card-aboutme {
        transform: scale(0.9);
    }
    .card-aboutme img {
        width: 250px;
    }
}

/* 针对超小屏幕的优化（手机竖屏） */
@media (max-width: 480px) {
    .card, .card-aboutme {
        padding: 10px;
        margin: 5px 0;
    }
    .card h2, .card-aboutme h2 {
        font-size: 1.2em;
        line-height: 1.3;
    }
    .card p, .card-aboutme p {
        font-size: 0.9em;
        line-height: 1.4;
    }
    .card-icons {
        flex-wrap: wrap;
        gap: 5px;
    }
    .icon-button {
        font-size: 0.8em;
        padding: 5px 10px;
    }
}

/* 针对平板横屏的优化 */
@media (max-width: 1024px) and (min-width: 769px) {
    .card-aboutme {
        transform: scale(0.95);
    }
    .card-aboutme img {
        width: 200px;
    }
    .card img {
        width: 200px;
    }
}

/* 确保卡片在容器中正确显示 */
.card-container, .card-container-aboutme {
    overflow-x: hidden;
}

/* 改进卡片的文字换行 */
.card h2, .card-aboutme h2 {
    word-wrap: break-word;
    hyphens: auto;
    line-height: 1.4;
}

.card p, .card-aboutme p {
    word-wrap: break-word;
    hyphens: auto;
}

/* LinkedIn图标颜色改为黑色 */
.fa-linkedin {
    color: #000 !important;
}


/* project01 */

.large-title {
    font-size: 4rem;
    /* 调整为你想要的大小 */
    font-weight: bold;
    /* 可选，增加字体粗细 */
}

.project-info {
    display: flex;
    justify-content: space-around;
    background-color: #fff;
    padding: 2rem;
    margin: 1rem auto;
    max-width: 1200px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.info-box {
    text-align: center;
}


/* 项目图片的样式 */

.project-image {
    display: flex;
    justify-content: center;
    padding: 2rem;
}

.project-image img {
    max-width: 100%;
    height: auto;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-radius: 0px;
}

.card-icons {
    position: static;
    display: flex;
    gap: 10px;
    margin-top: 15px;
    justify-content: flex-start;
}

.icon-button img {
    width: 24px;
    /* 图标大小可根据需要调整 */
    height: 24px;
    transition: transform 0.2s;
}

.card-icons .icon-button {
    color: #A9A9A9 !important;
    /* 浅灰色 */
}

.card-icons .icon-button:hover {
    color: #808080 !important;
    /* 悬停时变为稍深的灰色 */
}

.icon-button:hover img {
    transform: scale(1.1);
    /* 悬停时稍微放大 */
}

.framework {
    transform: scale(0.8);
    transform-origin: top left;
    display: inline-block;
    justify-content: left;
    padding-left: 2rem;
    padding-right: 2rem;
    padding-top: 2rem;
    padding-bottom: 0rem;
}