/* Specific shapes styles reusing some hub properties */
.game-container {
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 40px;
    padding: 4vw;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2), inset 0 0 0 6px rgba(255, 107, 107, 0.3);
    border: 6px solid #fff;
    max-width: 900px;
    width: 95%;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 40px;
}

header h1 {
    font-size: 3.5rem;
    font-weight: 900;
    color: #ff4757;
    margin-bottom: 5px;
    text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.1);
    letter-spacing: -1px;
}

header p {
    font-size: 1.6rem;
    font-weight: 700;
    color: #57606f;
    margin-bottom: 25px;
    background: #fff;
    display: inline-block;
    padding: 8px 25px;
    border-radius: 30px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.game-area {
    display: flex;
    flex-direction: column;
    gap: 50px;
    width: 100%;
    align-items: center;
}

.holes-container, .shapes-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    width: 100%;
}

/* Shapes and Holes Base */
.hole {
    width: 100px;
    height: 100px;
    border: 4px dashed #bdc3c7;
    border-radius: 15px;
    background-color: rgba(241, 242, 246, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background-color 0.2s;
}

.shape {
    width: 100px;
    height: 100px;
    cursor: grab;
    touch-action: none; /* Crucial for custom pointer events */
    filter: drop-shadow(0px 8px 0px rgba(0,0,0,0.15)) drop-shadow(0px 15px 20px rgba(0,0,0,0.15));
    transition: transform 0.1s, filter 0.1s;
    user-select: none;
    -webkit-user-select: none;
    z-index: 10;
}

.shape:active {
    cursor: grabbing;
    transform: scale(1.05) translateY(4px);
    filter: drop-shadow(0px 2px 0px rgba(0,0,0,0.1)) drop-shadow(0px 5px 10px rgba(0,0,0,0.1));
}

.shape.dragging {
    position: fixed;
    z-index: 9999;
    transition: none; /* Remove transition so it follows finger instantly */
    transform: scale(1.1);
    filter: drop-shadow(0px 15px 0px rgba(0,0,0,0.1)) drop-shadow(0px 25px 30px rgba(0,0,0,0.2));
    pointer-events: none; /* Important: let events pass through to find holes if needed, though we use coordinate-based check */
}

/* Specific Shapes */
.triangle {
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
    background-color: #ff6b6b;
}

.circle {
    border-radius: 50%;
    background-color: #4ecdc4;
}

.square {
    border-radius: 15px; /* slight rounding to look friendly */
    background-color: #5f27cd;
}

.star {
    clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
    background-color: #feca57;
}

.hole[data-shape="triangle"] { clip-path: polygon(50% 0%, 0% 100%, 100% 100%); border-radius: 0; }
.hole[data-shape="circle"] { border-radius: 50%; }
.hole[data-shape="square"] { border-radius: 15px; }
.hole[data-shape="star"] { clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); border-radius: 0;}

/* State Classes */
.hole.filled {
    border: 4px solid #2ed573;
    background-color: #e8f8f5;
    box-shadow: inset 0 0 20px rgba(46, 213, 115, 0.2);
}

.shape.snapped {
    cursor: default;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
    transform: translateY(4px);
}


.btn {
    background-color: #2ed573;
    color: white;
    border: none;
    border-radius: 50px;
    padding: 15px 30px;
    font-size: 1.3rem;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 8px 0 #21a351, 0 15px 20px rgba(0,0,0,0.1);
    transition: transform 0.15s, box-shadow 0.15s;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 20px;
    outline: none;
}

.btn:hover { transform: translateY(-2px); box-shadow: 0 10px 0 #21a351, 0 18px 25px rgba(0,0,0,0.15); }
.btn:active { transform: translateY(6px); box-shadow: 0 2px 0 #21a351; }


@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.08); }
    100% { transform: scale(1); }
}

.shape.active-pulse {
    animation: pulse 1.5s infinite ease-in-out;
}

@media (max-width: 600px) {
    .hole, .shape { width: 80px; height: 80px; }
    .game-area { gap: 30px; }
}

