/* WooCommerce Lucky Numbers - Estilos CSS */

#lucky_numbers_field {
    margin: 20px 0;
    padding: 20px;
    border: 2px solid #ddd;
    border-radius: 8px;
    background: #f9f9f9;
}

#lucky_numbers_field h3 {
    margin-top: 0;
    color: #333;
    font-size: 1.4em;
    border-bottom: 2px solid #0073aa;
    padding-bottom: 10px;
}

.lucky-numbers-product {
    margin-bottom: 25px;
    padding: 15px;
    background: white;
    border-radius: 6px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.lucky-numbers-product h4 {
    margin: 0 0 10px 0;
    color: #0073aa;
    font-size: 1.2em;
}

.lucky-numbers-product p {
    margin: 0 0 15px 0;
    color: #666;
}

.lucky-numbers-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 10px;
    max-height: 300px;
    overflow-y: auto;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fafafa;
}

.lucky-number-option {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border: 2px solid #ddd;
    border-radius: 8px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
    margin: 0;
}

.lucky-number-option:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.lucky-number-option.number-available {
    border-color: #0073aa;
    color: #0073aa;
}

.lucky-number-option.number-available:hover {
    background: #0073aa;
    color: white;
}

.lucky-number-option.number-used {
    border-color: #dc3232;
    background: #f1f1f1;
    color: #999;
    cursor: not-allowed;
    opacity: 0.6;
}

.lucky-number-option.number-used:hover {
    transform: none;
    box-shadow: none;
}

.lucky-number-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    cursor: pointer;
}

.lucky-number-option input[type="radio"]:disabled {
    cursor: not-allowed;
}

.lucky-number-option input[type="radio"]:checked + .number-display {
    color: white;
}

.lucky-number-option input[type="radio"]:checked {
    background: #0073aa;
}

.lucky-number-option input[type="radio"]:checked ~ * {
    color: white;
}

.lucky-number-option:has(input[type="radio"]:checked) {
    background: #0073aa;
    color: white;
    border-color: #005177;
    transform: scale(1.1);
}

.number-display {
    font-size: 18px;
    font-weight: bold;
    pointer-events: none;
    z-index: 1;
}

.used-indicator {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #dc3232;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

.loading {
    grid-column: 1 / -1;
    text-align: center;
    padding: 20px;
    color: #666;
    font-style: italic;
}

.error-message {
    color: #dc3232;
    font-size: 14px;
    margin-top: 10px;
    padding: 10px;
    background: #ffeaea;
    border: 1px solid #dc3232;
    border-radius: 4px;
}

/* Responsividade */
@media (max-width: 768px) {
    .lucky-numbers-container {
        grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
        gap: 8px;
    }
    
    .lucky-number-option {
        width: 50px;
        height: 50px;
    }
    
    .number-display {
        font-size: 16px;
    }
    
    #lucky_numbers_field {
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .lucky-numbers-container {
        grid-template-columns: repeat(auto-fill, minmax(45px, 1fr));
        gap: 6px;
    }
    
    .lucky-number-option {
        width: 45px;
        height: 45px;
    }
    
    .number-display {
        font-size: 14px;
    }
}

/* Animações */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.lucky-number-option.number-available:active {
    animation: pulse 0.3s ease;
}

/* Estado de loading melhorado */
.loading::after {
    content: '...';
    animation: dots 1.5s infinite;
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}


