
:root {
    --google-blue: #1a73e8;
    --bg-main: #ffffff;
    --bg-sub: #f8f9fa;
    --text-title: #202124;
    --text-body: #5f6368;
    --border: #e0e0e0;
    --max-width: 1200px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    background: var(--bg-main);
    color: var(--text-title);
    font-family: 'Inter', 'Roboto', sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 16px; }

/* --- Header --- */
header.site-header {
    background: #fff; border-bottom: 1px solid var(--border);
    position: sticky; top: 0; z-index: 1000; height: 64px; display: flex; align-items: center;
}
.header-inner { display: flex; justify-content: space-between; align-items: center; width: 100%; }
.logo { font-size: 22px; font-weight: 800; color: var(--text-title); text-decoration: none; letter-spacing: -1px; }
.logo span { color: var(--google-blue); }

.search-container {
    flex: 0 1 400px; background: #f1f3f4; height: 40px; border-radius: 20px;
    display: flex; align-items: center; padding: 0 15px; margin: 0 20px;
}
.search-container input { border: none; background: transparent; width: 100%; outline: none; margin-left: 8px; font-size: 14px; }

/* --- Layout --- */
.layout-wrapper { display: flex; margin-top: 24px; gap: 32px; min-height: 60vh; }

/* Sidebar (PC Only) */
.sidebar { width: 220px; flex-shrink: 0; display: none; }
.side-nav { list-style: none; position: sticky; top: 88px; }
.side-nav li { margin-bottom: 4px; }
.side-nav a {
    display: flex; align-items: center; gap: 12px; text-decoration: none;
    color: var(--text-body); padding: 10px 16px; border-radius: 12px; font-size: 14px; transition: 0.2s;
}
.side-nav a:hover { background: #f1f3f4; }
.side-nav a.active { background: #e8f0fe; color: var(--google-blue); font-weight: 600; }

/* Mobile Categories (Mobile Only) */
.mobile-cats { display: flex; overflow-x: auto; gap: 8px; padding-bottom: 16px; margin-bottom: 10px; scrollbar-width: none; }
.mobile-cats::-webkit-scrollbar { display: none; }
.cat-pill {
    background: var(--bg-sub); padding: 8px 16px; border-radius: 20px;
    border: 1px solid var(--border); font-size: 13px; white-space: nowrap;
    text-decoration: none; color: var(--text-body); font-weight: 500;
}
.cat-pill.active { background: var(--google-blue); color: #fff; border-color: var(--google-blue); }

.main-feed { flex: 1; min-width: 0; }

/* --- Grid --- */
.game-grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
.game-entry {
    display: flex; align-items: center; padding: 16px; background: #fff;
    border: 1px solid var(--border); border-radius: 16px; text-decoration: none; color: inherit; transition: 0.2s;
}
.game-entry:hover { border-color: var(--google-blue); box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
.entry-icon { width: 64px; height: 64px; border-radius: 12px; overflow: hidden; flex-shrink: 0; background: #f1f3f4; }
.entry-icon img { width: 100%; height: 100%; object-fit: cover; }
.entry-info { padding-left: 16px; flex: 1; }
.entry-info h3 { font-size: 16px; font-weight: 600; margin-bottom: 4px; }
.entry-info p { font-size: 13px; color: var(--text-body); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* --- Footer Description Area --- */
.footer-desc { margin-top: 60px; padding-top: 40px; border-top: 1px dashed var(--border); }
.footer-desc h2 { font-size: 18px; margin-bottom: 16px; color: var(--text-title); }
.footer-desc p { font-size: 14px; color: var(--text-body); line-height: 1.8; margin-bottom: 12px; }

/* --- Main Footer --- */
footer { padding: 60px 0 30px; border-top: 1px solid var(--border); background: var(--bg-sub); }
.footer-content { display: grid; grid-template-columns: 1fr; gap: 40px; margin-bottom: 40px; }

.footer-links-group h4 { font-size: 14px; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 16px; color: #9aa0a6; }
.footer-links-group ul { list-style: none; }
.footer-links-group ul li { margin-bottom: 10px; }
.footer-links-group ul a { color: var(--text-body); text-decoration: none; font-size: 14px; transition: 0.2s; }
.footer-links-group ul a:hover { color: var(--google-blue); }

.footer-bottom { border-top: 1px solid #e0e0e0; padding-top: 30px; text-align: center; }
.copyright { font-size: 12px; color: #9aa0a6; }

/* --- Scroll Top --- */
#scrollTop {
    position: fixed; bottom: 24px; right: 24px; width: 48px; height: 48px;
    background: var(--text-title); color: #fff; border-radius: 50%;
    display: none; align-items: center; justify-content: center; cursor: pointer; z-index: 1001;
}

/* --- Responsive --- */
@media (min-width: 768px) {
    .sidebar { display: block; }
    .mobile-cats { display: none; } /* Hide mobile nav on desktop */
    .game-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-content { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 1100px) {
    .game-grid { grid-template-columns: repeat(3, 1fr); }
}
