
:root {
    --bg-page: #f9f9f9; /* 页面背景：浅灰色 */
    --bg-header: #fff; /* 头部背景：白色 */
    --color-brand: #F47B00; /* 品牌色：亮橙色 */
    --color-text-dark: #333; /* 主文本：深灰色 */
    --color-text-muted: #666; /* 次要文本：中灰色 */
    --color-link: #4169E1; /* 链接色：蓝色 */
    --color-accent: #E55451; /* 强调色：红色 (用于评分等) */
    --color-border: #ddd; /* 边框：浅灰色 */
    --font-stack: 'Arial', 'Tahoma', 'Verdana', sans-serif;
    --content-width: 1100px;
}

/* --- 全局样式 --- */
body {
    font-family: var(--font-stack);
    margin: 0;
    padding: 0;
    background-color: var(--bg-page);
    color: var(--color-text-dark);
    font-size: 14px;
    line-height: 1.5;
}

a {
    text-decoration: none;
    color: var(--color-link);
    transition: color 0.2s;
}

a:hover {
    text-decoration: underline;
    color: var(--color-brand);
}

.container {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 10px;
}

/* --- 头部 (Header Bar) --- */
.igroutka-header {
    background-color: var(--bg-header);
    border-bottom: 1px solid var(--color-border);
    padding: 15px 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

/* Logo */
.header-logo a {
    font-size: 32px;
    font-weight: 700;
    color: var(--color-brand);
    letter-spacing: -1px;
    text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.1);
    text-decoration: none;
}

/* Search Form (橙色边框、圆角) */
.header-search {
    flex-grow: 1;
    max-width: 500px;
    display: flex;
    border: 2px solid var(--color-brand);
    border-radius: 20px;
    overflow: hidden;
    background-color: #fff;
}

.header-search input[type="text"] {
    flex-grow: 1;
    padding: 8px 15px;
    border: none;
    font-size: 15px;
    outline: none;
    color: var(--color-text-dark);
}

.header-search button {
    background-color: var(--color-brand);
    color: white;
    border: none;
    padding: 0 15px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.header-search button:hover {
    background-color: #e06e00; /* Darker orange */
}

/* Icons/User Area (使用 Unicode 字符模仿图标) */
.header-user-icons {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 20px;
}

.header-user-icons a {
    color: var(--color-text-muted);
    line-height: 1;
    text-decoration: none;
}

.header-user-icons a:hover {
    color: var(--color-brand);
}

/* --- 顶部导航栏 (Nav Bar) --- */
.igroutka-nav {
    background-color: #f0f0f0; /* 导航栏背景：浅灰色 */
    border-bottom: 1px solid var(--color-border);
}

.nav-links {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links li a {
    display: block;
    padding: 10px 15px;
    font-weight: 600;
    color: var(--color-text-dark);
    text-transform: uppercase;
    font-size: 13px;
    text-decoration: none;
}

.nav-links li a:hover,
.nav-links .nav-active a {
    background-color: var(--color-brand);
    color: white;
    text-decoration: none;
}

/* --- 主内容区域 (Main Layout) --- */
.igroutka-main-layout {
    display: flex;
    gap: 20px;
}

.main-content {
    flex-grow: 1;
    width: 70%; /* 主内容区宽 */
}

.main-sidebar {
    width: 300px; /* 侧边栏固定宽 */
    min-width: 300px;
    background-color: var(--bg-header);
    border: 1px solid var(--color-border);
    border-radius: 5px;
    padding: 15px;
    box-sizing: border-box;
    height: fit-content;
}

/* --- 游戏列表标题 (橙色底线) --- */
.section-header {
    font-size: 24px;
    font-weight: 700;
    color: var(--color-text-dark);
    margin-bottom: 15px;
    padding-bottom: 5px;
    border-bottom: 2px solid var(--color-brand);
    display: inline-block;
}

/* --- 游戏卡片网格 (Game Grid) --- */
.game-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.game-card {
    background-color: var(--bg-header);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.2s;
}

.game-card:hover {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.game-card a {
    display: block;
    text-decoration: none;
    color: inherit;
}

.game-thumb {
    aspect-ratio: 4 / 3; /* 图片比例接近 4:3 */
    overflow: hidden;
}

.game-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.game-card:hover .game-thumb img {
    transform: scale(1.05);
}

.game-info {
    padding: 10px;
    text-align: center;
}

.game-title {
    font-size: 15px;
    font-weight: 700;
    margin: 0 0 5px 0;
    color: var(--color-text-dark);
}

.game-card:hover .game-title {
    color: var(--color-brand);
}

.game-rating {
    font-size: 12px;
    color: var(--color-accent);
    font-weight: 600;
}

/* --- 侧边栏内容 --- */
.sidebar-block {
    margin-bottom: 20px;
    border-bottom: 1px solid var(--color-border);
    padding-bottom: 15px;
}

.sidebar-block h3 {
    font-size: 18px;
    color: var(--color-brand);
    text-transform: uppercase;
    margin: 0 0 10px 0;
    font-weight: 700;
}

.sidebar-list {
    list-style: none;
    padding: 0;
}

.sidebar-list li {
    padding: 5px 0;
    border-bottom: 1px dotted var(--color-border);
}

.sidebar-list a {
    color: var(--color-text-dark);
    font-size: 14px;
    text-decoration: none;
}

.sidebar-list a:hover {
    color: var(--color-brand);
    text-decoration: underline;
}

/* --- 页脚 (Footer) --- */
.igroutka-footer {
    background-color: #e0e0e0;
    padding: 20px 0;
    color: var(--color-text-muted);
    font-size: 13px;
    border-top: 1px solid var(--color-border);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    padding-bottom: 15px;
}

.footer-section {
    width: 200px;
}

.footer-section h4 {
    font-size: 16px;
    color: var(--color-text-dark);
    margin: 0 0 10px 0;
    font-weight: 700;
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links a {
    color: var(--color-text-muted);
    padding: 2px 0;
    display: block;
    font-size: 13px;
}

/* --- 响应式调整 --- */
@media (max-width: 900px) {
    .header-content {
        flex-wrap: wrap;
        justify-content: center;
    }
    .header-logo {
        width: 100%;
        text-align: center;
        margin-bottom: 10px;
    }
    .header-search {
        order: 3;
        max-width: 100%;
    }
    .header-user-icons {
        order: 2;
    }
    .igroutka-main-layout {
        flex-direction: column;
    }
    .main-content, .main-sidebar {
        width: 100%;
        min-width: unset;
        order: 1;
    }
    .main-sidebar {
        order: 2;
        padding: 10px;
    }
    .nav-links {
        justify-content: center;
        flex-wrap: wrap;
    }
    .game-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
    .footer-content {
        justify-content: center;
        text-align: center;
    }
    .footer-section {
        width: 100%;
    }
    .footer-links ul {
        text-align: center;
    }
}