* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #4F46E5;
    --primary-hover: #4338CA;
    --secondary: #F59E0B;
    --secondary-hover: #D97706;
    --accent: #10B981;
    --bg-default: #F8FAFC;
    --bg-paper: #FFFFFF;
    --bg-subtle: #F1F5F9;
    --text-primary: #1E293B;
    --text-secondary: #64748B;
    --text-muted: #94A3B8;
    --border-color: #E2E8F0;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-default);
    color: var(--text-primary);
    line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Fredoka', sans-serif;
    line-height: 1.2;
}

button,
.btn {
    font-family: 'Nunito', sans-serif;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

.navbar {
    background: white;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}

.nav-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    font-weight: bold;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary), #9333EA);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.logo-text {
    font-size: 1.5rem;
    background: linear-gradient(to right, var(--primary), #9333EA);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.hamburger {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    position: relative;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s;
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    top: 8px;
}

.nav-links {
    display: flex;
    gap: 0.25rem;
}

.nav-link {
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 600;
    transition: all 0.2s;
}

.nav-link:hover,
.nav-link.active {
    background: #EEF2FF;
    color: var(--primary);
}

.nav-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.btn-icon {
    padding: 0.5rem 1rem;
    border-radius: 999px;
    background: var(--bg-subtle);
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
}

.btn-icon:hover {
    background: #FEF3C7;
    color: var(--secondary);
}

.favorites-count {
    background: var(--secondary);
    color: white;
    padding: 0.125rem 0.5rem;
    border-radius: 999px;
    font-size: 0.75rem;
}

.btn-primary {
    padding: 0.75rem 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 999px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Hero */
.hero {
    position: relative;
    background: linear-gradient(135deg, var(--primary), #9333EA, #EC4899);
    min-height: 80vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    color: white;
}

.hero-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    opacity: 0.3;
}

.floating-shape {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    animation: float 6s ease-in-out infinite;
}

.shape-1 {
    width: 8rem;
    height: 8rem;
    top: 5rem;
    left: 2.5rem;
    filter: blur(40px);
}

.shape-2 {
    width: 12rem;
    height: 12rem;
    top: 10rem;
    right: 5rem;
    filter: blur(60px);
    animation-delay: 1s;
}

.shape-3 {
    width: 10rem;
    height: 10rem;
    bottom: 5rem;
    left: 25%;
    filter: blur(40px);
    animation-delay: 2s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}

.hero-content {
    position: relative;
    z-index: 10;
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
    padding: 3rem 0;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(8px);
    padding: 0.5rem 1rem;
    border-radius: 999px;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: bold;
    margin-bottom: 1rem;
}

.gradient-text {
    background: linear-gradient(to right, #fde047, #fbcfe8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: clamp(1.125rem, 2vw, 1.5rem);
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.125rem;
    border-radius: 999px;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

.hero-image {
    position: relative;
    display: none;
}

.hero-stats {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.stat-card {
    background: white;
    color: var(--text-primary);
    padding: 1.5rem;
    border-radius: 1rem;
    box-shadow: var(--shadow-xl);
    animation: pulse 2s infinite;
}

.stat-1 {
    animation-delay: 0s;
}

.stat-2 {
    animation-delay: 0.5s;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

.section {
    padding: 5rem 0;
    background: white;
}

.section-gray {
    background: var(--bg-default);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: #EEF2FF;
    color: var(--primary);
    border-radius: 999px;
    font-weight: 600;
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1rem;
}

.section-description {
    font-size: 1.25rem;
    color: var(--text-secondary);
}

.section-footer {
    text-align: center;
    margin-top: 3rem;
}

/* Games Grid */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.game-card {
    background: white;
    border-radius: 1.5rem;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s;
    text-decoration: none;
    color: inherit;
    display: block;
}

.game-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.game-image {
    position: relative;
    height: 192px;
    background: linear-gradient(135deg, #EEF2FF, #F3E8FF);
    overflow: hidden;
}

.game-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.game-difficulty {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.875rem;
    font-weight: bold;
    color: white;
}

.difficulty-easy {
    background: var(--accent);
}

.difficulty-medium {
    background: var(--secondary);
}

.difficulty-hard {
    background: #EF4444;
}

.game-content {
    padding: 1.5rem;
}

.game-category {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.game-title {
    font-size: 1.25rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.game-description {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.game-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.game-plays {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.game-btn {
    padding: 0.5rem 1rem;
    background: var(--primary);
    color: white;
    border-radius: 999px;
    font-weight: bold;
    font-size: 0.875rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: 1.5rem;
    box-shadow: var(--shadow-sm);
    text-align: center;
    transition: all 0.3s;
}

.feature-card:hover {
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary), #9333EA);
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 1rem;
}

.feature-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.feature-description {
    color: var(--text-secondary);
}

.cta-section {
    background: linear-gradient(to right, var(--primary), #9333EA);
    color: white;
    text-align: center;
}

.cta-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1rem;
}

.cta-description {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    max-width: 42rem;
    margin-left: auto;
    margin-right: auto;
}

.btn-white {
    background: white;
    color: var(--primary);
}

.btn-white:hover {
    background: #fde047;
    color: var(--primary);
}

.footer {
    background: #0F172A;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-title {
    font-size: 1.125rem;
    margin-bottom: 1rem;
}

.footer-text {
    color: #94A3B8;
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #94A3B8;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.btn-small {
    padding: 0.5rem 1.5rem;
    background: var(--primary);
    color: white;
    border-radius: 999px;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    font-size: 0.875rem;
}

.footer-bottom {
    border-top: 1px solid #1E293B;
    padding-top: 2rem;
    text-align: center;
    color: #94A3B8;
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 1rem;
        border-top: 1px solid var(--border-color);
        box-shadow: var(--shadow-md);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-actions {
        display: none;
    }
}

@media (min-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr 1fr;
    }

    .hero-image {
        display: block;
    }
}
.hero-visual { position: relative; display: none; }
.rocket-animation { position: relative; height: 400px; display: flex; align-items: center; justify-content: center; }
.rocket { font-size: 6rem; animation: fly 3s ease-in-out infinite; }
@keyframes fly { 0%, 100% { transform: translateY(0) rotate(-45deg); } 50% { transform: translateY(-30px) rotate(-35deg); } }
.stars .star { position: absolute; font-size: 2rem; animation: twinkle 2s ease-in-out infinite; }
.star-1 { top: 20%; left: 15%; animation-delay: 0s; }
.star-2 { top: 60%; right: 20%; animation-delay: 0.5s; }
.star-3 { bottom: 30%; left: 25%; animation-delay: 1s; }
.star-4 { top: 40%; right: 30%; animation-delay: 1.5s; }
@keyframes twinkle { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.2); } }
.numbers .number { position: absolute; font-size: 1.5rem; font-weight: bold; color: white; animation: bounce 2s ease-in-out infinite; }
.num-1 { top: 15%; left: 10%; animation-delay: 0s; }
.num-2 { top: 70%; right: 15%; animation-delay: 0.5s; }
.num-3 { bottom: 25%; left: 20%; animation-delay: 1s; }
.num-4 { top: 50%; right: 25%; animation-delay: 1.5s; }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-15px); } }
@media (min-width: 1024px) { .hero-visual { display: block; } }

.logo-image { width: 40px; height: 40px; object-fit: contain; filter: drop-shadow(0 0 10px rgba(139, 92, 246, 0.6)); }
.logo-image-small { width: 30px; height: 30px; object-fit: contain; filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.5)); }

.math-circle { position: relative; width: 400px; height: 400px; margin: 0 auto; }
.math-symbol { position: absolute; width: 60px; height: 60px; background: rgba(255,255,255,0.15); backdrop-filter: blur(10px); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 2rem; font-weight: bold; color: white; animation: orbit 20s linear infinite; }
.center-rocket { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 120px; height: 120px; animation: pulse 3s ease-in-out infinite; }
.rocket-icon { width: 100%; height: 100%; filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.8)); }
.symbol-1 { top: 0; left: 50%; transform: translateX(-50%); animation-delay: 0s; }
.symbol-2 { top: 15%; right: 15%; animation-delay: -2.5s; }
.symbol-3 { top: 50%; right: 0; transform: translateY(-50%); animation-delay: -5s; }
.symbol-4 { bottom: 15%; right: 15%; animation-delay: -7.5s; }
.symbol-5 { bottom: 0; left: 50%; transform: translateX(-50%); animation-delay: -10s; }
.symbol-6 { bottom: 15%; left: 15%; animation-delay: -12.5s; }
.symbol-7 { top: 50%; left: 0; transform: translateY(-50%); animation-delay: -15s; }
.symbol-8 { top: 15%; left: 15%; animation-delay: -17.5s; }
@keyframes orbit { 0% { transform: rotate(0deg) translateX(170px) rotate(0deg); } 100% { transform: rotate(360deg) translateX(170px) rotate(-360deg); } }
@media (max-width: 768px) { .math-circle { width: 300px; height: 300px; } .center-rocket { width: 80px; height: 80px; } .math-symbol { width: 50px; height: 50px; font-size: 1.5rem; } @keyframes orbit { 0% { transform: rotate(0deg) translateX(120px) rotate(0deg); } 100% { transform: rotate(360deg) translateX(120px) rotate(-360deg); } } }

@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
body { animation: fadeIn 0.5s ease-out; }

.btn-primary, .btn-large, .btn-secondary, .btn-white, .btn-small { transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); }
.btn-primary:hover, .btn-large:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 10px 25px rgba(79, 70, 229, 0.3); }
.btn-primary:active, .btn-large:active { transform: translateY(0) scale(0.98); }

a { transition: all 0.2s ease; }
.nav-link { position: relative; overflow: hidden; }
.nav-link::before { content: ''; position: absolute; bottom: 0; left: 0; width: 100%; height: 2px; background: var(--primary); transform: translateX(-100%); transition: transform 0.3s ease; }
.nav-link:hover::before, .nav-link.active::before { transform: translateX(0); }
