:root {
    --primary: #2c3e50;
    --accent: #3498db;
    --bg: #f4f7f6;
}
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg);
    margin: 0;
    padding: 0;
    color: #333;
}
/* Header styles for sub-pages */
header {
    background-color: var(--primary);
    color: white;
    padding: 2rem 0;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.apps-header {
    background-color: #3498db;
}
.games-header {
    background-color: #e74c3c;
}
header h1 { margin: 0; font-size: 2.5rem; }
header p { margin-top: 0.5rem; opacity: 0.8; }

.container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 20px;
}
.section-title {
    border-bottom: 2px solid #ddd;
    padding-bottom: 10px;
    margin: 40px 0 20px;
    color: var(--primary);
    text-transform: capitalize;
}
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}
.card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}
.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}
.card-image {
    height: 180px;
    background-color: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    text-decoration: none;
    position: relative;
}
.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.card:hover .card-image img {
    transform: scale(1.05);
}
.card-image .no-img { font-size: 3rem; color: #adb5bd; }
.card-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.card-title {
    margin: 0 0 15px;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary);
}
.card-description {
    font-size: 0.95rem;
    color: #666;
    margin: 0 0 15px;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.btn {
    margin-top: auto;
    display: block;
    background-color: var(--accent);
    color: white;
    text-align: center;
    padding: 10px;
    border-radius: 5px;
    text-decoration: none;
    transition: background 0.2s;
}
.btn:hover { background-color: #2980b9; }
.search-container {
    margin-bottom: 30px;
    text-align: center;
}
#searchInput {
    padding: 12px 20px;
    width: 100%;
    max-width: 500px;
    border: 1px solid #ddd;
    border-radius: 25px;
    font-size: 16px;
    outline: none;
    transition: box-shadow 0.3s;
}
#searchInput:focus {
    box-shadow: 0 0 8px rgba(52, 152, 219, 0.3);
    border-color: var(--accent);
}
.badge-new {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: #e74c3c;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    z-index: 10;
}
.navbar {
    background-color: var(--primary);
    color: white;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.brand { font-size: 1.5rem; font-weight: bold; color: white; text-decoration: none; }
.nav-links a { color: white; text-decoration: none; margin-left: 20px; font-weight: 500; transition: opacity 0.2s; }
.nav-links a:hover { opacity: 0.8; }
.hero {
    background: linear-gradient(-45deg, #2c3e50, #3498db, #2980b9, #1abc9c);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    color: white;
    padding: 80px 20px;
    text-align: center;
    margin-bottom: 0;
}
@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
.hero h1 { font-size: 3rem; margin: 0 0 10px; }
.hero p { font-size: 1.2rem; opacity: 0.9; max-width: 600px; margin: 0 auto; }
.about-section {
    background: white;
    padding: 40px 20px;
    text-align: center;
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
}
.about-section h2 { color: var(--primary); margin-top: 0; }
.about-section p { color: #666; max-width: 800px; margin: 0 auto; line-height: 1.6; }
.footer {
    background-color: var(--primary);
    color: white;
    padding: 2rem 0;
    margin-top: 40px;
    text-align: center;
}
.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
.social-links {
    margin-top: 10px;
}
.social-links a {
    color: white;
    margin: 0 10px;
    text-decoration: none;
    opacity: 0.8;
    transition: opacity 0.2s;
}
.social-links a:hover {
    opacity: 1;
}