* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
    touch-action: pan-y;
}

body {
    background: linear-gradient(135deg, #e0c3fc 0%, #8ec5fc 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.mobile-container {
    width: 100%;
    max-width: 480px;
    height: 100vh;
    background: #f4f7f6;
    position: relative;
    box-shadow: 0 20px 50px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

@media (min-width: 480px) {
    .mobile-container {
        border-radius: 40px;
        height: 90vh;
        max-height: 850px;
        border: 12px solid #fff;
    }
}

.app-header {
    background: #fff;
    padding: 2.5rem 1.5rem 2rem 1.5rem;
    color: #2d3748;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom-left-radius: 35px;
    border-bottom-right-radius: 35px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    position: relative;
    z-index: 10;
}

.user-greeting {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-greeting .avatar {
    font-size: 3rem;
    background: #edf2f7;
    border-radius: 50%;
    width: 65px;
    height: 65px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: inset 0 2px 5px rgba(0,0,0,0.05);
}

.user-greeting p {
    font-size: 1rem;
    color: #718096;
    font-weight: 600;
}

.user-greeting h1 {
    font-size: 1.6rem;
    font-weight: 800;
    color: #2d3748;
    letter-spacing: -0.5px;
}

.points {
    background: linear-gradient(135deg, #f6d365 0%, #fda085 100%);
    padding: 0.6rem 1.2rem;
    border-radius: 20px;
    font-weight: 800;
    font-size: 1.1rem;
    color: #fff;
    box-shadow: 0 4px 10px rgba(253, 160, 133, 0.4);
}

.games-grid {
    flex: 1;
    padding: 2rem 1.5rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding-bottom: 100px;
}

.game-btn {
    text-decoration: none;
    display: flex;
    align-items: center;
    padding: 1.5rem;
    border-radius: 24px;
    color: white;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.2s;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    position: relative;
    overflow: hidden;
}

.game-btn::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 50%;
    background: linear-gradient(180deg, rgba(255,255,255,0.2) 0%, rgba(255,255,255,0) 100%);
    pointer-events: none;
}

.game-btn:hover, .game-btn:active {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}

.game-btn .icon {
    font-size: 3.5rem;
    margin-right: 1.2rem;
    background: rgba(255,255,255,0.25);
    width: 80px;
    height: 80px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 20px;
    flex-shrink: 0;
    backdrop-filter: blur(5px);
    box-shadow: inset 0 2px 10px rgba(255,255,255,0.3);
}

.game-btn .details h3 {
    font-size: 1.5rem;
    margin-bottom: 0.4rem;
    font-weight: 800;
}

.game-btn .details p {
    font-size: 1rem;
    opacity: 0.95;
    line-height: 1.3;
    font-weight: 600;
}

/* Vibrant App Colors */
.color-1 { background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 99%, #fecfef 100%); color: #2d3748; }
.color-1 .details h3 { color: #d53f8c; }
.color-1 .details p { color: #97266d; }

.color-2 { background: linear-gradient(135deg, #84fab0 0%, #8fd3f4 100%); color: #2d3748; }
.color-2 .details h3 { color: #00877a; }
.color-2 .details p { color: #005a51; }

.color-3 { background: linear-gradient(135deg, #fccb90 0%, #d57eeb 100%); color: #2d3748; }
.color-3 .details h3 { color: #c05621; }
.color-3 .details p { color: #9c4221; }

.color-4 { background: linear-gradient(135deg, #a18cd1 0%, #fbc2eb 100%); color: #2d3748; }
.color-4 .details h3 { color: #553c9a; }
.color-4 .details p { color: #44337a; }

.bottom-nav {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 80px;
    background: #fff;
    border-top-left-radius: 30px;
    border-top-right-radius: 30px;
    display: flex;
    justify-content: space-around;
    align-items: center;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.05);
    z-index: 100;
    padding-bottom: 10px; /* Safe area */
}

.nav-item {
    text-align: center;
    color: #a0aec0;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    transition: color 0.2s, transform 0.2s;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}
.nav-item:hover, .nav-item.active {
    color: #667eea;
    transform: translateY(-2px);
}
.nav-item.active div {
    color: #667eea;
    filter: drop-shadow(0 2px 4px rgba(102, 126, 234, 0.4));
}

@media (max-width: 480px) {
    .app-header { padding: 1.5rem 1rem 1rem 1rem; border-bottom-left-radius: 20px; border-bottom-right-radius: 20px;}
    .user-greeting .avatar { width: 55px; height: 55px; font-size: 2.2rem; }
    .user-greeting h1 { font-size: 1.5rem; }
    .points { font-size: 1rem; padding: 0.5rem 1rem; }
    
    .games-grid { padding: 1rem; gap: 1rem; padding-bottom: 80px; justify-content: space-evenly; }
    .game-btn { padding: 1rem; border-radius: 16px; }
    .game-btn .icon { width: 55px; height: 55px; font-size: 2.2rem; margin-right: 0.8rem; border-radius: 12px; }
    .game-btn .details h3 { font-size: 1.2rem; margin-bottom: 0.1rem; }
    .game-btn .details p { font-size: 0.9rem; line-height: 1.2;}
    
    .bottom-nav { height: 65px; }
    .nav-item { font-size: 0.75rem; }
    .nav-item div { font-size: 1.3rem !important; }
}
