body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
}


  a {
            text-decoration: none;
            transition: all 0.3s ease;
        }

        /* 链接颜色 */
        a:link, a:visited {
            color: #333;
        }

        a:hover, a:active {
            color: #333;
        }


.container {
    width: 96%;
    margin: 20px auto;
}

.container a:hover {
            color: #ff9900;
        }

.category-title {
    text-align: center;
    margin-bottom: 20px;
    border: 1px solid #E6E6E6;
    border-radius: 5px;
    padding: 10px;
}

.waterfall {
    column-width: 250px;
    column-gap: 15px;
}

.item {
    display: inline-block;
    width: 100%;
    margin-bottom: 15px;
    break-inside: avoid;

    border: 1px solid #E6E6E6;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

  .item:hover {
    border: 1px solid #E0E0E0;
      transform: translateY(-5px) scale(1.03);
       box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  }

.item a {
    display: block;

}

.item img {
    width: 100%;
    height: auto;
    display: block;
}

.item p {
    padding: 10px;
    margin: 0;
    text-align: center;
    font-size: 12px; 
}

 /* 手机设备 */
@media only screen and (max-width: 768px) {
    .nav {
        flex-direction: column;
    }
    
    .menu {
        margin-top: 15px;
        flex-direction: column;
        width: 100%;
    }
    
    .menu li {
        margin: 5px 0;
        text-align: center;
    }
    
    .content {
        flex-direction: row; /* 改为行排列 */
        flex-wrap: wrap; /* 允许换行 */
    }
    
    .main, .sidebar {
        flex: 0 0 50%; /* 每列占50%宽度 */
        box-sizing: border-box; /* 包含内边距和边框在宽度内 */
        padding: 0 5px; /* 添加一些间距 */
    }
}

/* 平板设备 */
@media only screen and (min-width: 768px) and (max-width: 1024px) {
    .main {
        flex: 60%;
    }
    
    .sidebar {
        flex: 40%;
    }
}
