/* index.html 特化样式 */

body {
    background-color: #212121; /* 强制背景一致 */
}

.container {
    width: 100%;
    max-width: 800px;
    padding: 40px 20px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.card {
    background-color: #383838;
    padding: 24px 28px;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.card h3 {
    color: #ffffff;
    margin-top: 0;
}

.card h1 {
    color: #00e676;
    margin-top: 0;
}

.card p {
    color: #e4e4e7;
    line-height: 1.6;
}

.card a {
    color: #00e676;
    text-decoration: none;
}

.card a:hover {
    text-decoration: underline;
}

.card-image {
    display: block;
    margin: 12px auto;
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    background-color: #303030;
}

/* footer */
.footer {
    text-align: center;
    margin: 60px 0 20px 0;
    font-size: 14px;
    color: #888;
}

.footer a {
    color: #888;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

/* 顶栏 Topbar */
.topbar {
    background-color: #1c1c1c;
    height: 52px;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 28px;
    box-sizing: border-box;
    position: sticky; /* 可保持顶部悬浮，也可改为fixed */
    top: 0;
    //margin: 0;
    z-index: 1000;
}

/* 左侧标题 */
.topbar-title {
    color: #e4e4e7;
    font-size: 20px;
    font-weight: bold;
}

/* 右侧导航栏 */
.topbar-nav a {
    color: #e4e4e7;
    text-decoration: none;
    margin-left: 24px;
    font-size: 15px;
    transition: color 0.2s ease;
}

.topbar-nav a:hover {
    color: #00e676;
}

.video-wrapper {
    /* 核心修改 A：移除所有与固定比例相关的属性 */
    /* 移除: position: relative; */
    /* 移除: padding-bottom: 56.25%; */
    /* 移除: overflow: hidden; */
    
    /* 保持并优化居中和最大宽度 */
    width: 100%;
    max-width: 100%; /* 限制视频最大宽度，留出卡片边距 */
    margin: 16px auto; /* 上下 16px, 左右 auto 实现水平居中 */

    border-radius: 6px;
    background-color: #303030;
    
    /* 注意：此版本不再需要 position: relative; */
}


.video-wrapper video {
    /* 核心修改 B：让视频直接充满包装器，并保持自身比例 */
    
    /* 移除: position: absolute; */
    /* 移除: top: 0; left: 0; */
    
    width: 100%; /* 宽度撑满 .video-wrapper */
    height: auto; /* 高度根据视频原始比例自动计算，实现等比例缩放 */
    
    /* 核心属性：确保视频内容和播放器尺寸匹配 */
    object-fit: contain; /* 或者 cover，但为了保持完整性，推荐 contain 或不设置 */
    display: block; /* 确保它是一个块级元素，方便宽度和居中控制 */
    
    border-radius: 2px; /* 使视频本身也有圆角 */
    border: none; 
}