:root{
    --themes-color: #cc3333;
}
/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 全局容器：PC端居中+阴影，移动端全屏 */
.case-wrapper {
    max-width: 1200px;
    margin: 30px auto;
    background: #fff;
    /*box-shadow: 0 1px 5px rgba(0,0,0,0.1);*/
    overflow: hidden;
    width: 95%; /* 移动端留边距 */
}

/* 核心布局：PC端左右分栏，移动端纵向排列 */
.case-container {
    display: flex;
    flex-direction: row; /* PC端横向 */
}

/* ========== 左侧分类栏 (PC端) - 匹配截图样式 ========== */
.case-sidebar {
    width: 240px;
    background-color: #fff; /* 侧边栏白色背景 */
    color: #333; /* 文字默认深灰色 */
    flex-shrink: 0;
    transition: all 0.3s ease;
}

/* 顶部标题栏：深蓝色背景+白色文字 */
.case-sidebar-header {
    background-color: var(--themes-color); 
    color: #fff; 
    padding: 15px 20px;
    font-size: 20px;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.case-sidebar-header .curname{
    display: none;
}
/* 移动端分类栏开关按钮（PC端隐藏） */
.case-sidebar-toggle {
    display: none;
    cursor: pointer;
    font-size: 20px;
}

/* 分类列表样式 */
.case-sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
    border: 1px solid #eee;
}

.case-sidebar-list li {
    border-bottom: 1px solid #eee; /* 分类项分隔线 */
}

.case-sidebar-list li:last-child {
    border-bottom: none;
}

.case-sidebar-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 20px;
    color: #333; /* 未选中文字深灰色 */
    text-decoration: none;
    transition: background 0.2s;
    font-size: 16px;
}

/* 当前分类高亮样式（匹配截图）- 移除禁用点击属性 */
.case-sidebar-list li.active a {
    color: var(--themes-color); /* 深蓝色背景 */
    /* 已删除：cursor: default; 和 pointer-events: none; */
}

/* 空分类样式（可选：浅灰色文字，区分有数据/无数据） */
/*.case-sidebar-list li.empty a {*/
    color: #999; /* 空分类文字浅灰色 */
/*}*/

/* 高亮分类的箭头也改为白色 */
.case-sidebar-list li.active a::after {
    color: #fff;
}

/* 空分类箭头也改为浅灰色 */
.case-sidebar-list li.empty a::after {
    color: #ccc;
}

/* ========== 右侧详情区 (PC端) ========== */
.case-content {
    flex: 1;
    padding: 15px 30px 0;
}

/* 顶部标题：匹配参考页的蓝色标签 */
.case-content-header {
    color: #333;
    display: inline-block;
    font-size: 18px;
    font-weight: 500;
    padding: 8px 0;
    white-space: nowrap;
    /*margin-bottom: 25px;*/
    /*border-radius: 2px;*/
}
.case-content-header:hover,
.case-content-header.cur{
    color: var(--themes-color);
}

/* 分隔线 */
.case-divider {
    border: none;
    border-top: 2px solid var(--themes-color);
    /*margin: 25px 0;*/
}

.case-featured-image {
    margin: 30px 0;
}

.case-featured-image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}

.case-body {
    font-size: 16px;
    line-height: 1.8;
    color: #333;
    margin-bottom: 15px;
}

/* 案例列表容器 */
.case-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

/* 单个案例卡片 */
.case-card {
    border: 1px solid #eee;
    border-radius: 4px;
    overflow: hidden;
    transition: box-shadow 0.2s;
}

.case-card:hover {
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
}
.case-card:hover .case-card-img img{
    transform: scale(1.1);
}
.case-card:hover .case-card-title{
    color: var(--themes-color);
}

/* 案例卡片图片 */
.case-card-img {
    width: 100%;
    aspect-ratio: 280/180;
    object-fit: cover;
    display: block;
    overflow: hidden;
}
.case-card-img img{
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s;
}

/* 案例卡片内容 */
.case-card-content {
    padding: 15px 20px;
}

.case-card-title {
    font-size: 18px;
    margin-bottom: 10px;
    color: #333;
}

.case-card-title a {
    color: inherit;
    text-decoration: none;
}

.case-card-title a:hover {
    color: var(--themes-color);
}

.case-card-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    /*margin-bottom: 15px;*/
}


/* 空内容提示 */
.case-empty-content {
    text-align: center;
    padding: 60px 20px;
    color: #999;
    font-size: 18px;
}

.case-empty-content p {
    margin-bottom: 20px;
}

/* ========== 分页样式 (完全匹配参考页) ========== */
.case-pagination {
    text-align: center;
    margin: 40px 0 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.case-pagination .pagination-inner {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.case-pagination a,
.case-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid #eee;
    color: #666;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.2s ease;
}

/* 选中页样式（匹配参考页蓝色） */
.case-pagination .current {
    background-color: var(--themes-color);
    color: #fff;
    border-color: var(--themes-color);
}

/* 上一页/下一页按钮 */
.case-pagination .prev,
.case-pagination .next {
    width: auto;
    padding: 0 15px;
}

/* hover效果 */
.case-pagination a:hover:not(.current) {
    border-color: var(--themes-color);
    color: var(--themes-color);
}

/* 禁用状态（上一页/下一页无内容时） */
.case-pagination .disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}
/* 正文内的标题/段落适配 */
.case-body h2 {
    font-size: 22px;
    color: var(--themes-color);
    margin: 20px 0 10px;
}

.case-body p {
    margin-bottom: 15px;
}

.case-footer {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid var(--themes-color);
}

.case-footer a {
    color: #666;
    text-decoration: none;
    font-size: 16px;
}

.case-footer a:hover {
    color: var(--themes-color);
}

.case-container .h_R {
  width: 200px;
  /*box-shadow: 0 1px 50px #efefef;*/
  padding: 24px 0 20px;
}
.case-container .h_R .h_tbox {
  position: relative;
  padding-bottom: 4px;
}
.case-container .h_R .h_tbox .h_title{
    margin: 0;
}
.case-container .h_R .h_tbox .h_title span {
  color: #222;
  font-weight: 400;
  font-size: 20px;
  background: linear-gradient(0deg, rgba(205, 51, 51, 0.3) 0px 10px, #0000 10px 100%);
}
.case-container .h_R .h_tbox::after {
  position: absolute;
  content: '';
  height: 2px;
  width: 100%;
  left: 0;
  bottom: -2px;
  background-color: var(--themes-color);
}
.case-container .h_R .h_tbox::before {
  position: absolute;
  content: '';
  border-top: 6px solid var(--themes-color);
  border-left: 6px solid #00000000;
  border-right: 6px solid #00000000;
  left: 64px;
  bottom: -8px;
}
.case-container .h_R .h_list .h_item {
  margin-top: 20px;
  display: block;
}
.case-container .h_R .h_list .h_item .h_img {
  aspect-ratio: 3/2;
  font-size: 0;
  overflow: hidden;
}
.case-container .h_R .h_list .h_item .h_img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: 0.3s ease-in-out;
}
.case-container .h_R .h_list .h_item .h_name {
  font-size: 16px;
  color: #3D3D3D;
  margin: 5px 0 0;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
  text-align: center;
}
.case-container .h_R .h_list .h_item:hover .h_img img {
  transform: scale(1.1);
}
.case-container .h_R .h_list .h_item:hover .h_name {
  color: var(--themes-color);
}
/* ========== 响应式适配 (移动端/平板) ========== */
@media (max-width: 768px) {
.case-container .h_R{
    display: none;
}
    /* 容器适配 */
    .case-wrapper {
        margin: 15px auto;
        width: 92vw;
    }

    /* 布局改为纵向排列 */
    .case-container {
        flex-direction: column;
    }

    /* 左侧分类栏：全屏宽度，默认折叠 */
    .case-sidebar {
        width: 100%;
        /* max-height: 0;  */
        overflow: hidden;
        border: none;
        /*border-bottom: 1px solid #eee;*/
    }

    /* 显示移动端开关按钮 */
    .case-sidebar-toggle {
        display: block;
    }
    .case-sidebar-list{
        border: none;
        display: none;
        /*max-height: 0;*/
        /*transition: all 0.3s ease;*/
    }
    .case-content-header,.case-divider{
        display: none;
    }
    .case-sidebar-list li{
        border: none;
        margin-top: 2px;
    }
    .case-sidebar-list li a{
        padding: 8px 16px;
        background: #f8f8f8;
        color: #333;
        font-size: 16px;
    }
    .case-sidebar-list li.active a{
        color: var(--themes-color);
    }


    /* 右侧详情区：适配移动端内边距 */
    .case-content {
        padding: 0;
    }

    .case-content-header {
        padding: 6px 20px;
        font-size: 16px;
    }

    .case-body {
        font-size: 15px;
        line-height: 1.7;
    }

    .case-footer a {
        font-size: 15px;
    }
    .case-sidebar-header{
        padding: 10px 20px;
    }
    .case-sidebar-header .name{
        display: none;
    }
    .case-sidebar-header .curname{
        display: block;
    }

    /* 案例列表改为单列 */
    .case-list {
        grid-template-columns: 1fr;
        gap: 15px;
        margin: 20px 0 0;
    }
    .case-pagination{
        margin: 0;
        border: none;
    }

    /* 移动端分页样式适配 */
    .case-pagination a,
    .case-pagination span {
        width: 35px;
        height: 35px;
        font-size: 13px;
    }
    .case-pagination .prev,
    .case-pagination .next {
        padding: 0 10px;
    }
    .case-featured-image{
        margin: 15px 0;
    }

.case-body{
    margin-bottom: 5px;
}
}

/* 平板适配 (768-992px) */
@media (min-width: 769px) and (max-width: 992px) {
    .case-sidebar {
        width: 200px;
    }

    .case-content {
        padding: 20px 25px;
    }

    .case-list {
        grid-template-columns: repeat(2, 1fr);
    }
}