/**
 * WDC Daily Wordsearch - Specific Styles
 * Supplements wordfind-mobile.css with daily game theming
 * Core puzzle styling comes from wordfind-mobile.css
 */

/* ============================================
   STATS MODAL (from puzzle-tiles.css)
   ============================================ */

.puzzle-stats-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 2147483647;
    animation: game-fadeIn 0.3s;
}

.puzzle-stats-content {
    position: relative;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    background: white;
    padding: 30px;
    border-radius: 10px;
    max-width: 400px;
    max-height: 80vh;
    overflow-y: auto;
}

.puzzle-stats-grid {
    display: flex;
    justify-content: space-around;
    margin: 20px 0;
}

.puzzle-stat-box {
    flex: 1;
    text-align: center;
}

.puzzle-stat-value {
    font-size: 2em;
    font-weight: bold;
}

.puzzle-stat-label {
    font-size: 0.9em;
    color: #666;
}

@keyframes game-fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Theme display styling */
#ds-theme-display {
    padding: 10px 15px;
    background: linear-gradient(135deg, #f3e5f5 0%, #e1bee7 100%);
    border-radius: 8px;
    margin-bottom: 15px;
}

/* Purple accent for word list border */
#words {
    border-color: #e1bee7 !important;
    background-color: #faf5fc !important;
}

/* Layout: 3-3-2-2 pattern for 10 words */
#words ul {
    display: grid !important;
    grid-template-columns: repeat(6, 1fr) !important;
    gap: 0 !important;
    padding: 5px 0 !important;
}

#words li {
    grid-column: span 2;
    text-align: center !important;
    padding: 6px 5px !important;
}

/* Last 4 items: center in rows of 2 */
#words li:nth-child(7) {
    grid-column: 2 / span 2;
}
#words li:nth-child(8) {
    grid-column: 4 / span 2;
}
#words li:nth-child(9) {
    grid-column: 2 / span 2;
}
#words li:nth-child(10) {
    grid-column: 4 / span 2;
}

#words .wordFound {
    color: #9C27B0 !important;
}

/* Progress indicator */
#ds-progress {
    font-weight: bold;
}

#ds-progress #ds-found-count {
    color: #9C27B0;
    font-size: 1.3em;
}

/* Already completed panel theming */
#ds-already-completed {
    background: linear-gradient(135deg, #f3e5f5 0%, #e1bee7 100%);
}

/* Stats modal purple theme */
#ds-stats-modal .puzzle-stats-content {
    border-top: 4px solid #9C27B0;
}

#ds-stats-modal .puzzle-stat-value {
    color: #9C27B0;
}

/* Solve/Reset button section */
#ds-solve-section {
    border-top: 1px dashed #ddd;
    padding-top: 15px;
    margin-top: 15px;
}

/* Completion overlay animation */
#ds-complete-overlay {
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

#ds-complete-overlay > div {
    animation: popIn 0.4s ease-out;
}

@keyframes popIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Responsive adjustments */
@media (max-width: 480px) {
    #ds-theme-display {
        padding: 8px 12px;
    }
    
    #ds-theme-display > div:first-child {
        font-size: 1.2em;
    }
}
