@font-face {
    font-family: 'HarmonyOS_Sans_Medium';
    src: url("../fonts/HarmonyOS_Sans_Medium.ttf");
}

/* 为繁体中文和日语添加更好的字体支持 */
html {
    font-family: 'HarmonyOS_Sans_Medium', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Helvetica Neue', Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
}

/* 繁体中文专用字体设置 */
html[lang="zh-tw"], html[lang="zh-hk"] {
    font-family: 'HarmonyOS_Sans_Medium', 'PingFang TC', 'Microsoft JhengHei', 'Noto Sans TC', 'Source Han Sans TC', sans-serif;
}

/* 日语专用字体设置 */
html[lang="ja"] {
    font-family: 'HarmonyOS_Sans_Medium', 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', 'Meiryo', 'Noto Sans JP', 'Source Han Sans JP', sans-serif;
}

* {
    margin: 0;
    word-break: break-all;
    box-sizing: border-box; /* 添加盒模型属性 */
}

body {
    font-family: inherit; /* 继承html元素的字体设置 */
    background-color: #f8f9fa; /* 添加轻微背景色 */
    color: #212529; /* 统一文字颜色 */
    line-height: 1.5; /* 改善行高 */
    -webkit-font-smoothing: antialiased; /* 平滑字体 */
    -moz-osx-font-smoothing: grayscale; /* Firefox平滑字体 */
    text-rendering: optimizeLegibility; /* 优化字体渲染 */
}

/* 主页面内容的主要容器类 */
.wu-content {
    position: absolute;
    left: 50%;
    top: 0;
    width: calc(100% - 40px);
    height: auto;
    min-height: calc(100% - 40px);
    padding: 20px;
    margin: 0;
    transform: translateX(-50%); /* 使容器水平居中 */
}

.wu-divide {
    position: relative;
    width: 100%;
}

/* 内联显示项目的通用块样式 */
.wu-block {
    position: relative;
    top: 0;
    margin: 10px 0;
    display: inline-block;
    vertical-align: top;
    transition: transform 0.3s ease; /* 添加块级元素过渡效果 */
}

.wu-shadow {
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1); /* 更现代的阴影效果 */
    transition: all 0.3s ease; /* 平滑过渡效果 */
    border: 1px solid rgba(0, 0, 0, 0.03); /* 微妙边框 */
}

/* 在悬停时添加微妙的阴影效果 */
.wu-shadow:hover {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-3px); /* 上浮效果 */
}

/* 常规框样式（宽度、填充、边框） */
.wu-box {
    width: calc(100% - 40px);
    height: auto;
    padding: 20px;
    border-radius: 12px; /* 增加圆角 */
    background-color: #fff; /* 明确的背景色 */
}

.wu-box:hover {
    transform: scale(0.99);
}

/* 链接样式 */
.wu-links a,
.wu-not a {
    text-decoration: none;
    color: rgb(33,37,41);
    transition: all 0.2s ease;
    padding: 3px 8px; /* 增加内边距便于点击 */
    border-radius: 4px; /* 轻微圆角 */
    display: inline-block; /* 使内边距生效 */
}

.wu-links a:hover,
.wu-not a:hover {
    text-decoration: none; /* 移除下划线 */
    color: #fff; /* 高对比度 */
    background: linear-gradient(90deg, #3a95e4, #4aa0e8); /* 渐变背景 */
}

.wu-links a {
    margin: 5px;
}

/* 带有背景和颜色的注意块样式 */
.wu-notice {
    background-color: rgb(194, 93, 93);
    padding: 12px 15px; /* 增加内边距 */
    color: white;
    border-left: rgb(114, 45, 45) 5px solid; /* 加粗边框 */
    margin: 15px 0;
    border-radius: 0 6px 6px 0; /* 右侧圆角 */
}

/* 字体样式 */
.wu-h1 {
    font-size: 32px; /* 更大字体 */
    font-weight: bold;
    margin-bottom: 10px; /* 增加间距 */
}

.wu-h2 {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 8px;
}

.wu-h3 {
    font-size: 18px;
    margin-bottom: 6px;
}

.wu-a {
    text-decoration: none;
    color: rgb(33,37,41);
}

/* 宽度类 */
.wu-mw {
    width: calc(100% - 20px);
}

.wu-hw {
    width: calc(50% - 23px);
}

/* 实用程序：确保文本不换行，使用省略号溢出 */
.no-wrap {
    white-space: nowrap; /* 防止文本换行 */
    overflow: hidden; /* 隐藏溢出文本 */
    text-overflow: ellipsis; /* 为溢出文本添加省略号 */
}

/* 标签样式 */
.tag {
    display: inline-block;
    padding: 5px 15px;
    background: #f0f2f5;
    border-radius: 20px;
    margin: 5px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.tag:hover {
    background: #e0e2e5;
    transform: translateY(-2px);
}

/* 项目项样式 */
.project-item {
    padding: 20px;
    margin: 15px 0;
    background: #f8f9fa;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.project-item:hover {
    background: #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

/* 联系方式样式 */
.contact-methods p {
    margin: 10px 0;
    padding: 12px 15px;
    background: #f8f9fa;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.contact-methods p:hover {
    background: #fff;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

/* 响应式设计 */
@media (max-width: 800px) {
    .no-wrap {
        font-size: 16px; /* 调整字体大小以适应框内 */
    }

    .wu-h1.no-wrap {
        font-size: 26px; /* 调整 .wu-h1 元素的字体大小 */
    }

    .wu-h2.no-wrap {
        font-size: 22px; /* 调整 .wu-h2 元素的字体大小 */
    }

    /* 视频标题特别处理 */
    #video .wu-h2.no-wrap {
        font-size: 20px;
    }

    /* 平板设备特别优化 */
    .wu-block {
        margin: 8px 0;
    }

    .wu-box {
        padding: 15px;
        width: 100%;
    }

    /* 减少内容容器边距 */
    .wu-content {
        width: calc(100% - 30px);
        padding: 15px;
    }
}

@media (max-width: 600px) {
    #video .wu-h2.no-wrap {
        font-size: 18px;
    }

    .wu-links a {
        margin: 4px 2px;
        font-size: 14px;
    }

    /* 进一步减少内容容器边距 */
    .wu-content {
        width: calc(100% - 20px);
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .profile img {
        width: 80px;
    }

    .nav-item {
        padding: 12px;
        font-size: 16px;
    }

    #video .wu-h2.no-wrap {
        font-size: 16px;
    }

    /* 移动设备额外优化 */
    .wu-block {
        margin: 5px 0;
        width: 100% !important; /* 强制单列布局 */
    }

    .wu-hw {
        width: 100% !important;
    }

    .wu-box {
        border-radius: 10px;
        padding: 12px;
        width: 100%;
    }

    .wu-links a {
        padding: 6px;
        margin: 3px 1px;
        font-size: 13px;
    }

    /* 移动设备最小边距 */
    .wu-content {
        width: calc(100% - 16px);
        padding: 8px;
    }
}

/* 特别处理视频区块的标题 */
#video .wu-box {
    overflow: hidden;
}

/* 页脚版权信息链接样式 - 使其看起来像普通文本 */
.wu-box p.no-wrap a {
    text-decoration: none;
    color: inherit;
}

/* 添加页面载入动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.wu-content {
    animation: fadeIn 0.5s ease-out;
}

/* 为友情链接区添加悬浮效果 */
.wu-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
}

/* 移动端点击优化：移除蓝色点击高亮与焦点外框 */
@media (hover: none) and (pointer: coarse) {
    a,
    button,
    .modal-btn,
    [role="button"],
    input,
    textarea {
        -webkit-tap-highlight-color: transparent; /* 移除Android/Chrome点击高亮 */
    }

    a:focus,
    button:focus,
    .modal-btn:focus,
    [role="button"]:focus,
    input:focus,
    textarea:focus {
        outline: none; /* 移除iOS/Safari默认焦点外框 */
    }
}

/* Spacing helpers */
.h-10 { height: 10px; }
.h-20 { height: 20px; }
.h-40 { height: 40px; }
.h-90 { height: 90px; }

/* Styles moved from inline styles in index.html */
#video {
    width: calc(65% - 23px);
}

#notice {
    width: calc(35% - 23px);
}

@media (max-width: 800px) {
    #video,
    #notice {
        width: 100%;
    }
}

.footer-link-img {
    text-decoration: none; 
    color: rgb(20, 20, 20);
}

.footer-link-img img {
    float: left; 
    height: 23px; 
    margin-right: 5px;
}
