/* Game specific styles for Cupcakes 2048 */

/* Main content layout for the game section */
.main-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    background-color: #fcebeb; /* A light, soft background for the game area */
    width: 100%;
}

.home-section {
    max-width: 800px;
    text-align: center;
    margin-bottom: 40px;
}

.section-title {
    font-size: 2.5em;
    color: #e91e63; /* Deep pink, cupcake-like */
    margin-bottom: 15px;
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
}

.breadcrumb-nav {
    margin-bottom: 20px;
}

.breadcrumb-list {
    display: flex;
    justify-content: center;
    gap: 10px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.breadcrumb-list li a {
    color: #e91e63;
    text-decoration: none;
    font-weight: 500;
}

.breadcrumb-list li {
    color: #777;
    font-weight: 500;
}

.section-description {
    font-size: 1.1em;
    color: #555;
    line-height: 1.6;
    max-width: 700px;
    margin: 0 auto 30px;
}

.game-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 40px;
    width: 100%;
    max-width: 550px; /* Limit game container width */
    background: #ffffff; /* White background for the game card */
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    padding: 25px;
    position: relative; /* For cover screen positioning */
}

#cupcake-game-heading {
    font-size: 2.8em;
    color: #e91e63;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
}

.game-wrapper {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.score-board {
    display: flex;
    justify-content: space-around;
    width: 100%;
    margin-bottom: 20px;
    gap: 10px;
}

.score-display {
    background-color: #f7e6f2; /* Lighter pink for score boxes */
    color: #e91e63;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 1.2em;
    font-weight: bold;
    text-align: center;
    flex: 1;
}

.grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    background: #ffb3d9; /* Base pink for grid background */
    padding: 10px;
    border-radius: 10px;
    touch-action: none; /* Prevent browser default scroll/zoom */
    width: 100%; /* Make grid responsive within its wrapper */
    aspect-ratio: 1; /* Keep it square */
}

.cell {
    aspect-ratio: 1; /* Makes cells square */
    background: #fff0f5; /* Lightest pink for empty cells */
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5em; /* Keep text visible for fallback/debug */
    font-weight: bold;
    color: #663300; /* Dark brown for contrast, if numbers were shown */
    transition: transform 0.1s ease-out, background-color 0.1s ease-out; /* Smooth transitions */

    /* Image specific styles for tiles */
    background-size: cover; /* Ensure image covers the tile */
    background-position: center; /* Center the image */
    background-repeat: no-repeat; /* Prevent image repetition */
    background-color: #fff; /* Default background for image tiles (e.g., if image has transparency) */
}

/* IMPORTANT: Remove or comment out these background-color rules if you are using images.
   The images will set the background. Keeping these might cause unexpected behavior
   or reduce performance. If your images are transparent, you might want a subtle color here. */
/*
.cupcake-1 { background-color: #ffe6f2; }
.cupcake-2 { background-color: #ffcced; }
.cupcake-3 { background-color: #ffb3e6; }
.cupcake-4 { background-color: #ff99de; }
.cupcake-5 { background-color: #ff80d6; }
.cupcake-6 { background-color: #ff66ce; }
.cupcake-7 { background-color: #ff4dc8; }
.cupcake-8 { background-color: #ff33c0; }
.cupcake-9 { background-color: #e62eb0; }
.cupcake-10 { background-color: #cc28a1; }
.cupcake-11 { background-color: #b32292; }
.cupcake-win { background-color: #ffd700; }
*/


.game-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    width: 100%;
}

.game-controls button,
#restart-btn {
    padding: 12px 25px;
    font-size: 1.1em;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.1s ease;
    outline: none;
}

#new-game-btn, #restart-btn {
    background-color: #4CAF50; /* Green */
    color: white;
}

#new-game-btn:hover, #restart-btn:hover {
    background-color: #45a049;
    transform: translateY(-2px);
}

#undo-btn {
    background-color: #f0ad4e; /* Orange-Yellow, a bit more distinct than grey */
    color: white;
}

#undo-btn:hover:not(:disabled) {
    background-color: #ec971f; /* Darker orange-yellow on hover */
    transform: translateY(-2px);
}

#undo-btn:disabled {
    background-color: #cccccc; /* Light grey when disabled */
    cursor: not-allowed;
    opacity: 0.6;
}

.cover-screen {
    position: absolute; /* Changed from fixed to absolute */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95); /* Semi-transparent white overlay */
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 10; /* Ensure it's above the game */
    border-radius: 15px; /* Match game-section border-radius */
    display: none; /* Hidden by default */
}

.cover-screen h2 {
    font-size: 2.5em;
    margin-bottom: 25px;
    color: #e91e63; /* Matching pink */
    text-align: center;
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
}

/* Social Sharing Buttons Section (from Doge2048) */
.social-share-section {
    margin: 40px 0;
    text-align: center;
    width: 100%;
    max-width: 800px;
    background-color: #ffffff;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.social-share-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.share-button {
    padding: 12px 25px;
    font-size: 1.1em;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    color: white;
    transition: background-color 0.3s ease, transform 0.1s ease;
    text-decoration: none; /* For the anchor tags */
}

.share-button.twitter {
    background-color: #1DA1F2;
}
.share-button.twitter:hover {
    background-color: #0c85d0;
    transform: translateY(-2px);
}

.share-button.facebook {
    background-color: #3b5998;
}
.share-button.facebook:hover {
    background-color: #2d4373;
    transform: translateY(-2px);
}

.share-button.whatsapp {
    background-color: #25D366;
}
.share-button.whatsapp:hover {
    background-color: #1faf55;
    transform: translateY(-2px);
}

/* SEO Content Section */
.seo-content-section {
    max-width: 800px;
    margin: 30px auto;
    padding: 25px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    font-size: 1.1em;
    line-height: 1.6;
    color: #333;
}

.seo-content-section h2 {
    color: #e91e63;
    margin-bottom: 15px;
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
}

.seo-features-list {
    list-style: none; /* Remove default bullets */
    padding: 0;
    margin-top: 15px;
}

.seo-features-list li {
    margin-bottom: 10px;
    padding-left: 25px; /* Space for custom bullet */
    position: relative;
    color: #555;
}

.seo-features-list li:before {
    content: "🧁"; /* Custom bullet */
    position: absolute;
    left: 0;
    color: #e91e63;
    font-size: 1.2em;
    line-height: 1;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .section-title, #cupcake-game-heading {
        font-size: 2em;
    }
    .score-display {
        font-size: 1em;
        padding: 8px 15px;
    }
    .cell {
        font-size: 2em;
    }
    .game-controls button, .share-button {
        padding: 10px 20px;
        font-size: 1em;
    }
    .cover-screen h2 {
        font-size: 2em;
    }
    .seo-content-section {
        padding: 15px;
        margin: 20px auto;
    }
}

@media (max-width: 480px) {
    .game-section {
        padding: 15px;
    }
    #cupcake-game-heading {
        font-size: 1.8em;
    }
    .score-display {
        font-size: 0.9em;
        padding: 7px 10px;
    }
    .grid {
        gap: 7px;
        padding: 7px;
    }
    .cell {
        font-size: 1.8em;
    }
    .game-controls button, .share-button {
        padding: 8px 15px;
        font-size: 0.9em;
    }
    .cover-screen h2 {
        font-size: 1.8em;
    }
    .social-share-buttons {
        flex-direction: column;
        align-items: center;
    }
}