* {
    box-sizing: border-box;
}

/* Base page styles for the landing page. */
body {
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

.hidden {
    display: none;
}

/* Hero section introducing the available game modes. */
.hero {
    text-align: center;
    padding: 1.5rem 1.5rem;
}

.hero h1 {
    font-size: 2.25rem;
    color: var(--text-primary);
}

.hero p {
    font-size: 1.125rem;
    color: var(--text-secondary);
}

/* Mode cards stay side-by-side on larger screens and stack on mobile. */
.mode-cards {
    display: flex;
    justify-content: center;
    gap: 2.5rem;
    padding: 2.5rem 1.5rem; 
}

.mode-card {
    background-color: var(--bg-card);
    border-radius: 12px;
    box-shadow: 4px 4px 6px var(--shadow-card);
    padding: 1.5rem;
    width: 380px;
    height: auto;
    text-align: center;
}

.mode-card h1 {
    font-size: 60px;
    padding: 0;
    margin: 0;
    margin-bottom: 0.75rem;
}

.mode-card h2 {
    font-size: 24px;
    padding: 0;
    margin: 0;
}

/* Primary actions share the same shape and sizing across both cards. */
#challenge-button,
#sandbox-button {
    color: white;
    font-size: 16px;
    font-weight: bold;
    border: none;
    border-radius: 24px;
    width: 180px;
    height: 46px;
    cursor: pointer;
}

#challenge-button {
    background-color: #2563EB;
}

#sandbox-button {
    background-color: #7C3AED;
}

#challenge-button:hover,
#sandbox-button:hover {
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(37, 99, 235, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 99, 235, 0);
    }
}   

/* Simplify the card presentation for narrower screens. */
@media screen and (max-width: 768px) {
    .mode-cards {
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
        padding: 1.5rem 1rem;
    }

    .mode-card p {
        display: none;
    }

    .mode-card h1 {
        font-size: 40px;
    }

    .mode-card h2 {
        margin-bottom: 0.5rem;
    }
}