/* 全局重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: "Microsoft YaHei", Arial, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}
a {
    text-decoration: none;
    color: #333;
    transition: all 0.2s;
}
a:hover {
    color: #cc0000;
}
img {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}
ul, li {
    list-style: none;
}

/* 容器 */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* 头部 */
.header {
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    padding: 15px 0;
    margin-bottom: 20px;
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo img {
    height: 50px;
}
.nav ul {
    display: flex;
}
.nav li {
    margin-left: 30px;
}
.nav li a {
    font-size: 16px;
    font-weight: 500;
    padding: 8px 0;
    display: inline-block;
}
.nav li.active a {
    color: #cc0000;
    border-bottom: 2px solid #cc0000;
}

/* 主体 */
.main {
    display: flex;
    gap: 20px;
}
.content {
    flex: 1;
    background: #fff;
    padding: 25px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.sidebar {
    width: 300px;
}

/* 面包屑 */
.position {
    font-size: 14px;
    color: #666;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px dashed #eee;
}

/* 图文文章列表 */
.article-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.article-item {
    display: flex;
    gap: 18px;
    padding-bottom: 20px;
    border-bottom: 1px dashed #eee;
}
.article-img {
    width: 140px;
    height: 105px;
    object-fit: cover;
    flex-shrink: 0;
    border-radius: 5px;
}
.article-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.article-title {
    font-size: 17px;
    font-weight: 500;
    margin-bottom: 8px;
    color: #222;
}
.article-desc {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.article-meta {
    font-size: 13px;
    color: #999;
    display: flex;
    gap: 20px;
}

/* 分页 */
.pagebar {
    margin-top: 30px;
    text-align: center;
}
.pagebar a {
    display: inline-block;
    padding: 6px 12px;
    margin: 0 4px;
    border: 1px solid #eee;
    border-radius: 3px;
    font-size: 14px;
}
.pagebar a.on {
    background: #cc0000;
    color: #fff;
    border-color: #cc0000;
}
.pagebar a:hover {
    background: #cc0000;
    color: #fff;
    border-color: #cc0000;
}

/* 侧边栏 */
.widget {
    background: #fff;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.widget-title {
    font-size: 18px;
    padding-bottom: 10px;
    margin-bottom: 15px;
    border-bottom: 2px solid #cc0000;
    color: #cc0000;
}
.photo-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.photo-grid a {
    font-size: 13px;
    text-align: center;
}
.photo-grid img {
    margin-bottom: 6px;
}
.hot-list li {
    line-height: 2.2;
    border-bottom: 1px dashed #eee;
    padding-left: 5px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 14px;
}
.hot-num {
    display: inline-block;
    width: 20px;
    height: 20px;
    line-height: 20px;
    text-align: center;
    background: #cc0000;
    color: #fff;
    font-size: 12px;
    border-radius: 2px;
    margin-right: 8px;
}

/* 游戏图文网格布局 */
.photo-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.photo-grid li {
  list-style: none;
  width: 48%;
  margin-bottom: 10px;
}
.photo-grid li a {
  display: block;
  text-align: center;
  font-size: 13px;
  color: #333;
  text-decoration: none;
}
/* 图片统一大小（核心） */
.photo-grid li a img {
  width: 100%;
  height: 90px;       /* 统一高度 */
  object-fit: cover;  /* 不变形、自动裁剪 */
  border-radius: 4px;
  margin-bottom: 5px;
  display: block;
}
/* 标题文字控制 */
.photo-grid li a {
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size:13px;
  line-height:1.4;
}

/* 底部 */
.footer {
    background: #2a2a2a;
    color: #aaa;
    text-align: center;
    padding: 25px 0;
    margin-top: 30px;
    font-size: 14px;
}
.footer a {
    color: #aaa;
}
.footer a:hover {
    color: #fff;
}

/* 响应式 */
@media (max-width: 992px) {
    .main {
        flex-direction: column;
    }
    .sidebar {
        width: 100%;
    }
}
@media (max-width: 768px) {
    .header-inner {
        flex-direction: column;
    }
    .nav ul {
        margin-top: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    .article-img {
        width: 110px;
        height: 85px;
    }
}