@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800&family=Space+Grotesk:wght@400;700&display=swap');

:root {
    --accent-cyan: #00f2fe;
    --accent-purple: #4facfe;
    --accent-pink: #f35588;
    --glow-shadow: 0 15px 40px rgba(0, 242, 254, 0.25);
}

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

body {
    /* 24-second infinite animation simulating the 24h day/night sky cycle */
    animation: skyCycle 24s infinite cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 2rem 0;
}

.minimal-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2.5rem;
    text-align: center;
    width: 100%;
    padding: 0 1.5rem;
}

.brand-title {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(1.2rem, 7vw, 3.8rem);
    font-weight: 600;
    letter-spacing: 0.25em;
    color: inherit; /* Dynamically inherits animated text color from body */
    user-select: none;
    text-indent: 0.25em;
    opacity: 0;
    animation: fadeIn 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.emblem-container {
    opacity: 0;
    animation: fadeIn 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Morphing animated wrapper - Outer Neon Frame */
.visual-wrapper {
    position: relative;
    width: clamp(180px, 65vw, 260px);
    height: clamp(180px, 65vw, 260px);
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    background: linear-gradient(45deg, var(--accent-cyan), var(--accent-purple), var(--accent-pink));
    animation: morphing 12s ease-in-out infinite alternate;
    padding: 5px;
    box-shadow: var(--glow-shadow);
    overflow: hidden;
    
    /* Hardware acceleration */
    will-change: border-radius;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Neural Network Canvas */
#coreCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background-color: #080b11;
    z-index: 1;
}

/* Glowing central cognitive core */
.central-core {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    background: radial-gradient(circle, #ffffff 0%, var(--accent-cyan) 40%, rgba(79, 172, 254, 0.4) 70%, transparent 100%);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    pointer-events: none;
    box-shadow: 0 0 25px var(--accent-cyan);
    animation: corePulse 3s ease-in-out infinite alternate;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Core soft breath pulse */
@keyframes corePulse {
    0% {
        transform: translate(-50%, -50%) scale(0.9);
        opacity: 0.8;
        box-shadow: 0 0 15px rgba(0, 242, 254, 0.5);
    }
    100% {
        transform: translate(-50%, -50%) scale(1.15);
        opacity: 1;
        box-shadow: 0 0 35px rgba(0, 242, 254, 0.9), 0 0 15px rgba(243, 85, 136, 0.4);
    }
}

/* Organic morphing border-radius animation */
@keyframes morphing {
    0% {
        border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    }
    25% {
        border-radius: 58% 42% 75% 25% / 56% 45% 55% 44%;
    }
    50% {
        border-radius: 50% 50% 33% 67% / 55% 27% 73% 45%;
    }
    75% {
        border-radius: 33% 67% 58% 42% / 63% 68% 32% 37%;
    }
    100% {
        border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    }
}

/* 24-second Sky Cycle (simulating 24h Day/Night) */
@keyframes skyCycle {
    /* 00:00 - Midnight (Deep space black-blue) */
    0%, 100% {
        background-color: #030712;
        color: #f3f4f6;
        --card-bg: rgba(255, 255, 255, 0.04);
        --card-border: rgba(255, 255, 255, 0.1);
        --card-shadow: rgba(0, 0, 0, 0.3);
        --text-muted: rgba(243, 244, 246, 0.7);
    }
    /* 06:00 - Sunrise/Dawn (Warm pastel pink/orange) */
    25% {
        background-color: #fecdd3; /* Soft rose */
        color: #0f172a;
        --card-bg: rgba(15, 23, 42, 0.03);
        --card-border: rgba(15, 23, 42, 0.08);
        --card-shadow: rgba(15, 23, 42, 0.05);
        --text-muted: rgba(15, 23, 42, 0.7);
    }
    /* 12:00 - Noon (Pure clean white) */
    50% {
        background-color: #ffffff;
        color: #0f172a;
        --card-bg: rgba(15, 23, 42, 0.03);
        --card-border: rgba(15, 23, 42, 0.08);
        --card-shadow: rgba(15, 23, 42, 0.05);
        --text-muted: rgba(15, 23, 42, 0.7);
    }
    /* 18:00 - Sunset/Dusk (Twilight purple/magenta) */
    75% {
        background-color: #2e1065; /* Deep purple */
        color: #f3f4f6;
        --card-bg: rgba(255, 255, 255, 0.04);
        --card-border: rgba(255, 255, 255, 0.1);
        --card-shadow: rgba(0, 0, 0, 0.3);
        --text-muted: rgba(243, 244, 246, 0.7);
    }
}

/* App Store Games Section */
.games-container {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
    padding: 1rem;
    width: 100%;
    max-width: 800px;
    margin-top: 1rem;
    opacity: 0;
    animation: fadeIn 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.6s forwards;
}

.game-card {
    position: relative;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    padding: 32px 24px;
    width: 295px;
    height: 520px;
    text-align: center;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 
        inset 0 1px 1px rgba(255, 255, 255, 0.08), 
        0 12px 32px var(--card-shadow);
    transition: 
        transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
        border-color 0.3s ease, 
        box-shadow 0.4s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: inherit;
    text-decoration: none;
}

.game-card:hover {
    transform: translateY(-6px);
}

.game-card.minesweeper:hover {
    border-color: var(--accent-cyan);
    box-shadow: 
        inset 0 1px 1px rgba(255, 255, 255, 0.1),
        0 20px 40px rgba(0, 242, 254, 0.12);
}

.game-card.jigsaw:hover {
    border-color: var(--accent-purple);
    box-shadow: 
        inset 0 1px 1px rgba(255, 255, 255, 0.1),
        0 20px 40px rgba(79, 172, 254, 0.12);
}

.game-icon {
    width: 160px;
    height: 160px;
    border-radius: 36px;
    object-fit: cover;
    margin-bottom: 22px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.game-card:hover .game-icon {
    transform: translateY(-4px) scale(1.03);
}

.game-card h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.35;
    height: 3.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

.game-card p {
    font-size: 0.85rem;
    line-height: 1.55;
    color: var(--text-muted);
    margin-bottom: 24px;
    flex-grow: 1;
}

.playstore-badge {
    width: 135px;
    height: auto;
    transition: transform 0.2s ease;
}

.playstore-badge:hover {
    transform: scale(1.04);
}

.badge-preview {
    position: absolute;
    top: 14px;
    right: 14px;
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-purple));
    color: #030712;
    font-size: 0.62rem;
    font-weight: 800;
    text-transform: uppercase;
    padding: 3px 8px;
    border-radius: 8px;
    letter-spacing: 0.05em;
    box-shadow: 0 4px 10px rgba(0, 242, 254, 0.2);
    user-select: none;
}

.preview-info {
    font-size: 0.75rem;
    margin-top: 16px;
    line-height: 1.45;
    color: var(--text-muted);
    max-width: 90%;
}

.preview-info a {
    color: var(--accent-cyan);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: opacity 0.2s;
}

.preview-info a:hover {
    opacity: 0.85;
}

.card-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    min-height: 100px;
    margin-top: auto; /* Pushes the entire footer to the bottom of the card */
}






