:root {
    --primary-color: #7C3AED;
    --secondary-color: #4F46E5;
    --dark-color: #1F2937;
    --light-color: #F9FAFB;
    --header-height: 60px;
    --sidebar-width: 250px;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

/* 侧边栏样式 */
.sidebar {
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
    z-index: 1000;
    width: 16.666667%; /* 相当于 col-2 */
    transition: transform 0.3s ease-in-out;
}

.sidebar .nav-link {
    color: rgba(255,255,255,0.8);
    padding: 0.8rem 0;
    transition: all 0.3s ease;
}

.sidebar .nav-link:hover,
.sidebar .nav-link.active {
    color: #fff;
    background-color: rgba(255,255,255,0.1);
    padding-left: 1rem;
}

/* Hero区域样式 */
.hero {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 6rem 0;
    margin-bottom: 2rem;
}

/* 卡片样式 */
.card {
    border: none;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
}

/* 视频容器样式 */
.video-wrapper {
    background-color: #000;
    width: 100%;
    margin: 0;
    overflow: hidden;
}

.video-container {
    position: relative;
    padding-top: 56.25%; /* 保持16:9的比例 */
    height: 0;
    overflow: hidden;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
}

/* 视频加载动画 */
.video-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
}

/* 视频卡片样式 */
.card {
    transition: transform 0.2s;
    background-color: #fff;
    border: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.card:hover {
    transform: translateY(-5px);
}

.card-title {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

/* 模态框中的视频容器 */
.video-container-modal {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
    padding: 0; /* 移除padding */
}

.video-container-modal iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    background-color: #000;
}

/* 响应式布局调整 */
@media (max-width: 768px) {
    .col-md-6 {
        padding: 0 8px;
    }
    
    .video-container {
        padding-top: 56.25%; /* 保持16:9比例 */
    }
    
    .modal-dialog {
        margin: 0.5rem;
    }
}

/* 大屏幕优化 */
@media (min-width: 1200px) {
    .modal-xl {
        max-width: 1140px; /* 增加模态框最大宽度 */
    }
    
    .video-container-modal {
        max-width: 1920px; /* 支持最高1080p分辨率 */
    }
}

/* 视频网格布局 */
.row.g-4 {
    margin: -12px;
}

.row.g-4 > [class*="col-"] {
    padding: 12px;
}

/* 展开按钮样式 */
.expand-video {
    width: 100%;
    margin-top: 0.5rem;
}

/* 加载状态样式 */
.loading .video-loader {
    display: flex;
}

.video-loader {
    display: none;
}

/* 模态框样式优化 */
.modal-dialog.modal-xl {
    max-width: 95vw;  /* 增加到95%视口宽度 */
    max-height: 95vh; /* 增加到95%视口高度 */
    margin: 1rem auto;
}

.modal-content {
    background-color: #000;
    border: none;
    border-radius: 8px;
    overflow: hidden;
    height: calc(95vh - 2rem); /* 设置固定高度 */
}

/* 模态框头部样式优化 */
.modal-header {
    border-bottom: none;
    padding: 0.5rem;  /* 减小内边距 */
    background-color: rgba(0, 0, 0, 0.5);  /* 更浅的背景色 */
    position: absolute;
    top: 0;
    right: 0;  /* 只固定在右侧 */
    left: auto;  /* 消左侧固定 */
    width: auto;  /* 宽度自适应 */
    z-index: 2;
    display: flex;
    justify-content: flex-end;  /* 右对齐 */
    align-items: center;
    border-radius: 0 0 0 8px;  /* 添加左下圆角 */
}

/* 隐藏标题，因为已经不需要了 */
.modal-title {
    display: none;
}

/* 关闭按钮样式优化 */
.btn-close-white {
    background-color: transparent;
    border: none;
    padding: 0.75rem;
    width: 2.5rem;
    height: 2.5rem;
    opacity: 0.7;
    transition: all 0.3s ease;
    position: relative;
    z-index: 3;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-close-white:hover {
    opacity: 1;
    background-color: rgba(255, 255, 255, 0.1);  /* 悬停时的背景效果 */
}

/* 关闭图标样式 */
.btn-close-white::before,
.btn-close-white::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 2px;
    background-color: white;
    transform-origin: center;
}

.btn-close-white::before {
    transform: rotate(45deg);
}

.btn-close-white::after {
    transform: rotate(-45deg);
}

/* 底部控制栏样式优化 */
.modal-footer {
    border-top: none;
    padding: 0.75rem;
    background-color: rgba(0, 0, 0, 0.5);  /* 更浅的背景色 */
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2;
    display: flex;
    justify-content: center;
}

/* 底部关闭按钮样式 */
.modal-footer .btn-secondary {
    background-color: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 0.5rem 2rem;
    transition: background-color 0.3s;
}

.modal-footer .btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

/* 添加键盘快捷键提示 */
.modal-footer .btn-secondary::after {
    content: '(ESC)';
    margin-left: 0.5rem;
    opacity: 0.7;
    font-size: 0.9em;
}

.nav-link.active {
    background-color: rgba(255, 255, 255, 0.1); /* 或者其他颜色 */
    color: #007bff; /* 选中状态的文字颜色 */
}

/* 导航栏样式 */
.sidebar {
    transition: transform 0.3s ease;
}

.mobile-header {
    z-index: 1030; /* 确保在其他元素之上 */
}

.nav-link {
    padding: 0.75rem 1rem; /* 增加内边距 */
}

.nav-link.active {
    background-color: rgba(255, 255, 255, 0.1); /* 选中状态的背景色 */
    color: #007bff; /* 选中状态的文字颜色 */
}

/* 移动端样式 */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%); /* 默认隐藏 */
    }

    .sidebar.show {
        transform: translateX(0); /* 显示 */
    }

    .mobile-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 0.5rem 1rem;
    }

    .navbar-toggler {
        border: none;
    }
} 

/* 移动端样式 */
.mobile-header {
    z-index: 1030; /* 确保在其他元素之上 */
}

.sidebar {
    position: fixed; /* 确保侧边栏固定 */
    top: 0;
    left: 0;
    height: 100vh; /* 侧边栏高度为视口高度 */
    width: 250px; /* 侧边栏宽度 */
    transform: translateX(-100%); /* 默认隐藏 */
    transition: transform 0.3s ease; /* 动画效果 */
    background-color: #343a40; /* 侧边栏背景色 */
    color: white; /* 侧边栏文字颜色 */
    overflow-y: auto; /* 允许垂直滚动 */
}

.sidebar.show {
    transform: translateX(0); /* 显示侧边栏 */
}

.nav-link {
    padding: 0.75rem 1rem; /* 增加内边距 */
    color: white; /* 链接颜色 */
}

.nav-link.active {
    background-color: rgba(255, 255, 255, 0.1); /* 选中状态的背景色 */
    color: #007bff; /* 选中状态的文字颜色 */
}

/* 汉堡菜单样式 */
.navbar-toggler {
    border: none; /* 去掉边框 */
}

.navbar-toggler-icon {
    background-color: white; /* 汉堡菜单图标颜色 */
} 

/* 导航栏基础样式 */
.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background-color: #0a0a0a;
    color: white;
    z-index: 1030;
    transition: transform 0.3s ease-in-out;
    display: flex;
    flex-direction: column;
}

/* 侧边栏内容容器 */
.sidebar-content {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
}

/* LOGO 样式 */
.sidebar .logo {
    padding-bottom: 1.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar .logo h1 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

/* 导航菜单样式 */
.sidebar .nav {
    flex: 1 1 auto;
    margin-bottom: 1.5rem;
}

/* 用户控制区样式 */
.sidebar .user-controls {
    margin-top: auto;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar .user-controls .language-selector {
    margin-bottom: 1rem;
}

.sidebar .user-controls .btn {
    margin-bottom: 0.5rem;
}

.sidebar .user-controls .btn:last-child {
    margin-bottom: 0;
}

/* 移动端顶部导航栏 */
.mobile-header {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background-color: #343a40;
    padding: 0.5rem 1rem;
    z-index: 1040;
}

/* 主内容区域 */
.main-content {
    min-height: 100vh;
    transition: margin-left 0.3s ease-in-out;
}

/* 导航链接样式 */
.nav-link {
    color: rgba(255, 255, 255, 0.8);
    padding: 0.8rem 1rem;
    transition: all 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}

/* 汉堡菜单按钮样式 */
.navbar-toggler {
    padding: 0.5rem;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 24px;
}

.navbar-toggler span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: white;
    transition: all 0.3s ease;
}

/* 遮罩层 */
.sidebar-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1025;
}

.sidebar-backdrop.show {
    display: block;
}

/* 响应式布局 */
@media (max-width: 991.98px) {
    /* 移动端显示顶部导航栏 */
    .mobile-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    /* 侧边栏在移动端默认隐藏 */
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.show {
        transform: translateX(0);
    }

    /* 主内容区域适应移动端 */
    .main-content {
        margin-left: 0 !important;
        padding-top: var(--header-height);
    }

    /* 移动端导航菜单样式 */
    .nav-link {
        padding: 1rem 1.5rem;
        font-size: 1.1rem;
    }
}

/* 大屏幕布局 */
@media (min-width: 992px) {
    .sidebar {
        transform: none !important;
    }

    .main-content {
        margin-left: var(--sidebar-width);
    }

    .mobile-header {
        display: none;
    }

    .sidebar-backdrop {
        display: none !important;
    }
} 

/* LOGO 样式 */
.sidebar .logo {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar .logo h1 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

/* 侧边栏内容布局 */
.sidebar .p-4 {
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* 导航菜单样式 */
.sidebar .nav {
    margin-top: 2rem;
    flex-grow: 1;
}

/* 用户控制区样式 */
.sidebar .user-controls {
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* 响应式调整 */
@media (max-width: 991.98px) {
    .sidebar .logo {
        display: none; /* 在移动端隐藏侧边栏的 LOGO */
    }
    
    .mobile-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
}

@media (min-width: 992px) {
    .mobile-header {
        display: none; /* 在大屏幕上隐藏移动端头部 */
    }
    
    .sidebar .logo {
        display: block; /* 在大屏幕上显示侧边栏的 LOGO */
    }
} 