/* 
 * Monster Survivors - Online Games Platform
 * Main Stylesheet
 * Apple-inspired color scheme
 */

/* Base Styles and Reset */
:root {
    /* Apple-inspired color palette */
    --primary-color: #0071e3; /* Apple blue */
    --primary-hover: #0077ed;
    --secondary-color: #86868b; /* Apple gray */
    --accent-color: #5ac8fa; /* Apple light blue */
    --success-color: #34c759; /* Apple green */
    --warning-color: #ff9500; /* Apple orange */
    --danger-color: #ff3b30; /* Apple red */
    --light-bg: #f5f5f7; /* Apple light background */
    --dark-text: #1d1d1f; /* Apple dark text */
    --medium-text: #515154; /* Apple medium gray text */
    --light-text: #86868b; /* Apple light gray text */
    --card-bg: #ffffff;
    --border-color: #d2d2d7;
    --shadow-color: rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background-color: var(--light-bg);
    color: var(--dark-text);
    line-height: 1.5;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Container */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Buttons */
.btn-primary {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    font-weight: 500;
    padding: 12px 30px;
    border-radius: 50px;
    font-size: 1rem;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    text-align: center;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px var(--shadow-color);
}

.control-btn {
    padding: 8px 16px;
    background-color: var(--light-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.control-btn:hover {
    background-color: var(--border-color);
}

.like-btn {
    background: transparent;
    border: none;
    color: var(--danger-color);
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
}

.like-btn i {
    font-size: 1.2rem;
}

/* Header */
.header {
    background-color: var(--card-bg);
    box-shadow: 0 1px 10px var(--shadow-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark-text);
}

.logo span {
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    gap: 25px;
}

.nav-links a {
    font-weight: 500;
    color: var(--dark-text);
    position: relative;
}

.nav-links a.active,
.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a.active::after,
.nav-links a:hover::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
}

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    color: white;
    padding: 80px 0;
    text-align: center;
    margin-bottom: 50px;
    border-radius: 0 0 30px 30px;
}

.hero-content {
    max-width: 700px;
    margin: 0 auto;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

/* Section Headers */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.section-header h2 {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--dark-text);
}

.view-all {
    color: var(--primary-color);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 5px;
}

.view-all:hover {
    text-decoration: underline;
}

/* Game Grid */
.game-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

.game-card {
    background-color: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 5px 15px var(--shadow-color);
}

.game-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px var(--shadow-color);
}

.game-thumbnail {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.game-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.game-card:hover .game-thumbnail img {
    transform: scale(1.05);
}

.game-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.game-card:hover .game-overlay {
    opacity: 1;
}

.play-btn {
    background-color: var(--primary-color);
    color: white;
    font-weight: 500;
    padding: 10px 25px;
    border-radius: 50px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.play-btn:hover {
    background-color: var(--primary-hover);
    transform: scale(1.05);
}

.game-info {
    padding: 15px;
}

.game-info h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--dark-text);
}

.game-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: var(--light-text);
}

.rating {
    color: var(--warning-color);
}

/* Categories Section */
.categories {
    margin: 50px 0;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
}

.category-card {
    background-color: var(--card-bg);
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 5px 15px var(--shadow-color);
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px var(--shadow-color);
}

.category-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.category-card h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.category-card p {
    font-size: 0.9rem;
    color: var(--medium-text);
}

/* Category Page */
.category-banner {
    background-color: var(--card-bg);
    padding: 30px 0;
    box-shadow: 0 5px 15px var(--shadow-color);
    margin-bottom: 30px;
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.search-box {
    display: flex;
    align-items: center;
}

.search-box input {
    padding: 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: 4px 0 0 4px;
    font-size: 0.9rem;
    width: 250px;
}

.search-box button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
}

.filter-tabs {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 10px;
}

.filter-btn {
    padding: 8px 16px;
    background-color: var(--light-bg);
    border: 1px solid var(--border-color);
    border-radius: 50px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.filter-btn.active,
.filter-btn:hover {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
    margin-bottom: 50px;
}

.pagination-btn {
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pagination-btn.active {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.pagination-btn:hover:not(.active) {
    background-color: var(--light-bg);
}

/* Game Page */
.game-showcase {
    padding: 30px 0;
}

.game-details {
    margin-bottom: 20px;
}

.game-details h2 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.game-details p {
    color: var(--medium-text);
    font-size: 1.1rem;
}

.game-frame-container {
    aspect-ratio: 16 / 9;
    width: 100%;
    overflow: hidden;
    border-radius: 12px;
    background-color: #000;
    box-shadow: 0 10px 30px var(--shadow-color);
    margin-bottom: 20px;
}

#game-frame {
    width: 100%;
    height: 100%;
    border: none;
}

.game-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.game-info {
    margin: 50px 0;
}

.game-description {
    background-color: var(--card-bg);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px var(--shadow-color);
}

.game-description h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
}

.game-meta-info {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.meta-item h4 {
    font-size: 1rem;
    margin-bottom: 5px;
    color: var(--medium-text);
}

.related-games h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

/* Footer */
.footer {
    background-color: var(--dark-text);
    color: white;
    padding: 50px 0 20px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    margin-bottom: 30px;
}

.footer-logo {
    flex: 1;
    min-width: 250px;
}

.footer-logo h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.footer-logo span {
    color: var(--primary-color);
}

.footer-logo p {
    color: rgba(255, 255, 255, 0.7);
}

.footer-links {
    flex: 2;
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
}

.footer-section {
    min-width: 150px;
}

.footer-section h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    font-weight: 600;
}

.footer-section ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.7);
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 992px) {
    html {
        font-size: 15px;
    }
    
    .hero {
        padding: 60px 0;
    }
    
    .hero h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }
    
    .nav-links {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background-color: var(--card-bg);
        flex-direction: column;
        align-items: center;
        padding: 50px 0;
        transition: left 0.3s ease;
        z-index: 99;
    }
    
    .nav-links.active {
        left: 0;
    }
    
    .category-header {
        flex-direction: column;
        gap: 20px;
    }
    
    .search-box {
        width: 100%;
    }
    
    .search-box input {
        width: 100%;
    }
    
    .game-controls {
        flex-wrap: wrap;
        gap: 10px;
    }
}

@media (max-width: 576px) {
    .hero {
        padding: 40px 0;
    }
    
    .hero h2 {
        font-size: 1.8rem;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .footer-content {
        flex-direction: column;
    }
    
    .category-grid,
    .game-grid {
        grid-template-columns: 1fr;
    }
} 