/* Custom variables for 2007-style minimal layout */
:root {
    --bg-main: #ffffff;
    --text-main: #222222;
    --text-muted: #555555;
    --color-link: #0055ff;
    --border-color: #cccccc;
    --font-stack: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-stack);
    font-size: 14px;
    line-height: 1.5;
    padding: 2rem 1.5rem;
}

.container {
    max-width: 960px;
    margin: 0 auto;
}

/* Header */
.navbar-header {
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 2.5rem;
    padding-bottom: 1rem;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.4rem;
    font-weight: bold;
}

.logo-accent {
    color: var(--text-muted);
}

.nav-links a {
    color: var(--color-link);
    text-decoration: none;
    font-weight: bold;
}

.nav-links a:hover {
    text-decoration: underline;
}

/* Intro Hero */
.hero-section {
    margin-bottom: 3rem;
    padding: 1.5rem 0;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.hero-desc {
    font-size: 1.1rem;
    color: var(--text-muted);
}

/* Grid Layouts */
section {
    margin-bottom: 3rem;
}

.section-header {
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: bold;
}

.featured-grid, .projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

/* Cards */
.featured-card, .project-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.portal-card {
    background-color: #fffdf0;
    border: 1px solid #cca300;
}

.card-body {
    padding: 15px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.game-title, .project-name {
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.game-title a, .project-name a {
    color: var(--color-link);
    text-decoration: none;
}

.game-title a:hover, .project-name a:hover {
    text-decoration: underline;
}

.game-tag {
    display: inline-block;
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: normal;
    margin-bottom: 0.5rem;
}

.game-desc, .project-description {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
    flex-grow: 1;
    line-height: 1.4;
}

/* Actions & Buttons */
.game-actions, .project-footer {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn, .project-link-btn {
    border: 1px solid var(--border-color);
    background-color: #f5f5f5;
    color: var(--text-main);
    padding: 4px 10px;
    font-size: 0.85rem;
    text-decoration: none;
    cursor: pointer;
    font-weight: bold;
}

.btn:hover, .project-link-btn:hover {
    background-color: #e8e8e8;
    border-color: #999999;
}

.project-stars {
    font-size: 0.8rem;
    color: #eab308;
    font-weight: bold;
}

.project-lang {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-family: monospace;
}

/* Loader & Fallback */
.loader-container {
    padding: 3rem 0;
    text-align: center;
    grid-column: 1 / -1;
}

.loader-text {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-family: monospace;
}

.fallback-container {
    grid-column: 1 / -1;
    border: 1px solid #ffcccc;
    background-color: #fff8f8;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.fallback-title {
    font-size: 1.1rem;
    font-weight: bold;
    color: #cc0000;
    margin-bottom: 0.5rem;
}

.fallback-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* Footer */
.footer {
    border-top: 1px solid var(--border-color);
    margin-top: 3rem;
    padding: 1.5rem 0 0 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* Responsiveness */
@media (max-width: 768px) {
    body {
        padding: 1rem;
    }
    
    .navbar {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .featured-grid, .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}
