/**
 * 前台深色风格样式（响应式）
 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Microsoft Yahei", sans-serif;
    background-color: #1a1a1a; /* 备用背景色（图片加载失败时显示） */
    color: #e0e0e0;
    line-height: 1.6;
    /* 背景图片核心样式 */
    background-image: url("https://bing.img.run/rand_uhd.php"); /* 指向背景图路径 */
    background-repeat: no-repeat; /* 禁止重复 */
    background-size: cover; /* 全屏覆盖（自适应屏幕） */
    background-position: center center; /* 居中显示 */
    background-attachment: fixed; /* 固定背景（滚动页面时背景不动） */
    /* 半透明遮罩（关键！保证文字可读性，适配深色风格） */
    position: relative;
}
/* 新增遮罩层，避免背景图干扰文字 */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(26, 26, 26, 0.65); /* 深色遮罩，0.85是透明度（可调整） */
    z-index: -1; /* 遮罩层放在最底层，不影响其他内容 */
}

/* 页头 */
.header {
    background-color: #666666;
    padding: 15px 0;
    border-bottom: 1px solid #444;
}

.header .container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 34px;
    font-weight: bold;
    color: #ffffff;
    text-decoration: none;
}

/* 搜索/筛选区域 */
.search-area {
    width: 90%;
    max-width: 1200px;
    margin: 20px auto;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.select-category {
    padding: 8px 12px;
    background-color: #666666;
    border: 1px solid #444;
    color: #e0e0e0;
    border-radius: 4px;
}

.search-input {
    flex: 1;
    min-width: 200px;
    padding: 8px 12px;
    background-color: #666666;
    border: 1px solid #444;
    color: #e0e0e0;
    border-radius: 4px;
}

.search-btn {
    padding: 8px 20px;
    background-color: #007acc;
    border: none;
    color: #ffffff;
    border-radius: 4px;
    cursor: pointer;
}

.search-btn:hover {
    background-color: #005f99;
}

/* 网站列表 */
.website-list {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    padding-bottom: 50px;
}

.website-item {
    background-color: #666666;
    border-radius: 8px;
    padding: 15px;
    transition: transform 0.2s;
}

.website-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.website-logo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin-bottom: 10px;
    object-fit: cover;
}

.website-name {
    font-size: 20px;
    font-weight: bold;
    color: #CCFF00;
    margin-bottom: 5px;
}

.website-intro {
    font-size: 14px;
    color: #FFFFFF;
    margin-bottom: 10px;
}

.website-link {
    display: inline-block;
    color: #66FF99;
    text-decoration: none;
    font-size: 16px;
}

.website-visit {
    font-size: 12px;
    color: #666;
    margin-top: 10px;
}

/* 页尾 */
.footer {
    background-color: #666666;
    padding: 15px 0;
    text-align: center;
    border-top: 1px solid #444;
    position: fixed;
    bottom: 0;
    width: 100%;
    font-size: 14px;
    color: #999;
}

/* 响应式适配（移动端） */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        gap: 10px;
    }
    .search-area {
        flex-direction: column;
        align-items: stretch;
    }
    .website-list {
        grid-template-columns: repeat(2, 1fr); /* 移动端一行显示2个内容 */
        gap: 15px; /* 适当减小间距适配小屏幕 */
    }
}