/* XSMB Random - Traditional Lottery Style with XX Prefix */

/* Force display with higher specificity */
body .xx-xsmb-random-container,
body div.xx-xsmb-random-container,
html body .xx-xsmb-random-container {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    z-index: 1 !important;
    clear: both !important;
    float: none !important;
}

body .xx-xsmb-results,
body div.xx-xsmb-results,
html body .xx-xsmb-results,
html body div.xx-xsmb-results {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    clear: both !important;
    float: none !important;
}

body .xx-xsmb-prize-row,
body div.xx-xsmb-prize-row,
html body .xx-xsmb-prize-row {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    clear: both !important;
    float: none !important;
}

body .xx-xsmb-header,
body div.xx-xsmb-header,
html body .xx-xsmb-header {
    position: relative !important;
    clear: both !important;
    float: none !important;
}

body .xx-xsmb-action,
body div.xx-xsmb-action,
html body .xx-xsmb-action {
    position: relative !important;
    clear: both !important;
    float: none !important;
}

body .xx-xsmb-statistics,
body div.xx-xsmb-statistics,
html body .xx-xsmb-statistics {
    position: relative !important;
    clear: both !important;
    float: none !important;
}

.xx-xsmb-random-container {
    max-width: 1000px !important;
    margin: 0 auto !important;
    font-family: Arial, 'Helvetica Neue', sans-serif !important;
    background: #fff !important;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15) !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Header */
.xx-xsmb-header {
    background: linear-gradient(135deg, #c41e3a 0%, #ff6b35 100%) !important;
    color: white !important;
    padding: 20px !important;
    text-align: center !important;
    position: relative !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.xx-xsmb-icon,
.xx-xsmb-icon-img {
    width: 32px !important;
    height: 32px !important;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    flex-shrink: 0 !important;
}

.xx-xsmb-icon-img {
    object-fit: contain !important;
    vertical-align: middle !important;
}

.xx-xsmb-title-wrapper {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    flex-wrap: nowrap !important;
}

.xx-title-separator {
    display: inline-block !important;
    line-height: 1 !important;
    font-weight: 300 !important;
}

.xx-xsmb-title {
    margin: 0 !important;
    font-size: 22px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3) !important;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    white-space: nowrap !important;
    line-height: 1.2 !important;
}

.xx-xsmb-datetime-wrapper {
    margin-top: 12px !important;
    text-align: center !important;
}

.xx-xsmb-date {
    font-size: 15px !important;
    font-weight: 400 !important;
    opacity: 0.95 !important;
    display: block !important;
    visibility: visible !important;
    color: white !important;
}

.xx-xsmb-date strong {
    font-weight: 700 !important;
    font-size: 16px !important;
    color: #ffeb3b !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3) !important;
}

.xx-xsmb-countdown {
    display: block !important;
    margin-top: 8px !important;
    font-size: 14px !important;
    color: white !important;
    opacity: 0.95 !important;
}

.xx-countdown-time {
    font-weight: 700 !important;
    font-size: 16px !important;
    color: #ffeb3b !important;
    font-family: 'Courier New', monospace !important;
    letter-spacing: 1px !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3) !important;
    margin: 0 4px !important;
}

/* Region Selector */
.xx-xsmb-region-selector {
    display: flex !important;
    justify-content: center !important;
    gap: 12px !important;
    padding: 15px 20px !important;
    background: #fff !important;
    border-bottom: 2px solid #e0e0e0 !important;
}

.xx-region-option {
    position: relative;
    cursor: pointer;
    display: flex;
    align-items: center;
}

.xx-region-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.xx-region-label {
    padding: 8px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    transition: all 0.3s ease;
    background: #fff;
}

.xx-region-option:hover .xx-region-label {
    border-color: #ff6b35;
    color: #ff6b35;
}

.xx-region-option input[type="radio"]:checked + .xx-region-label {
    background: linear-gradient(135deg, #ff6b35 0%, #d84315 100%);
    border-color: #ff6b35;
    color: white;
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.4);
}

/* Action Section */
.xx-xsmb-action {
    padding: 15px 20px !important;
    background: #fff !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    border-bottom: 2px solid #e0e0e0 !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.xx-xsmb-btn {
    background: linear-gradient(135deg, #ff6b35 0%, #d84315 100%);
    color: white;
    border: none;
    padding: 12px 40px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.4);
    text-transform: uppercase;
}

.xx-xsmb-btn:hover {
    background: linear-gradient(135deg, #ff8a65 0%, #e64a19 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 107, 53, 0.5);
}

.xx-xsmb-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.xx-xsmb-btn:disabled {
    background: #bdbdbd;
    border-color: #9e9e9e;
    color: #757575;
    cursor: not-allowed;
    transform: none;
}

.xx-btn-icon {
    width: 18px;
    height: 18px;
}

.xx-xsmb-btn.xx-spinning .xx-btn-icon {
    animation: xx-spin 1s linear infinite;
}

@keyframes xx-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Results Section */
.xx-xsmb-results {
    padding: 20px !important;
    background: white !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.xx-xsmb-prize-row {
    display: flex !important;
    align-items: center !important;
    padding: 12px 0 !important;
    border-bottom: 1px solid #f0f0f0 !important;
}

.xx-xsmb-prize-row:last-child {
    border-bottom: none !important;
}

.xx-xsmb-prize-row:first-child {
    background: #fffef0 !important;
    padding: 16px 0 !important;
    border-bottom: 2px solid #f0f0f0 !important;
}

.xx-prize-label {
    min-width: 60px !important;
    font-weight: 700 !important;
    color: #1a237e !important;
    font-size: 16px !important;
    text-align: left !important;
    margin-right: 20px !important;
    display: block !important;
}

.xx-prize-numbers {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    flex: 1 !important;
    align-items: center !important;
}

.xx-number-box {
    background: transparent !important;
    padding: 0 !important;
    border-radius: 0 !important;
    font-size: 24px !important;
    font-weight: 700 !important;
    font-family: 'Arial Black', 'Arial Bold', sans-serif !important;
    color: #1a1a1a !important;
    text-align: center !important;
    min-width: auto !important;
    border: none !important;
    transition: all 0.3s ease !important;
    letter-spacing: 1px !important;
    display: inline-block !important;
}

.xx-number-box.xx-special {
    font-size: 32px !important;
    color: #d32f2f !important;
    font-weight: 900 !important;
}

.xx-number-box.xx-loading {
    color: #d0d0d0 !important;
}

.xx-number-box.xx-animating {
    animation: xx-numberPulse 0.1s ease;
}

@keyframes xx-numberPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.xx-number-box.xx-revealed {
    animation: xx-revealNumber 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes xx-revealNumber {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }
    50% {
        transform: scale(1.15);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Statistics Section - Lottery Balls Style */
.xx-xsmb-statistics {
    padding: 25px 20px;
    background: #fffef0;
    border-top: 2px solid #e0e0e0;
}

.xx-stats-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-bottom: 20px !important;
}

.xx-stats-title {
    margin: 0 !important;
    font-size: 18px;
    font-weight: 700;
    color: #1a237e;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.xx-copy-btn {
    background: #4CAF50 !important;
    color: white !important;
    border: none !important;
    padding: 8px 16px !important;
    border-radius: 4px !important;
    cursor: pointer !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
}

.xx-copy-btn:hover {
    background: #45a049 !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15) !important;
}

.xx-copy-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

.xx-copy-btn.xx-copied {
    background: #2196F3 !important;
}

.xx-copy-btn.xx-copied::after {
    content: ' ✓';
}

.xx-loto-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
    gap: 12px;
    justify-items: center;
}

.xx-loto-ball {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: white;
    border: 3px solid #e0e0e0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 900;
    color: #1a1a1a;
    font-family: 'Arial Black', Arial, sans-serif;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    animation: xx-lotoAppear 0.4s ease;
    transition: transform 0.2s ease;
}

.xx-loto-ball:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.xx-loto-ball .xx-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #d32f2f;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

@keyframes xx-lotoAppear {
    from {
        opacity: 0;
        transform: scale(0.5);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .xx-xsmb-random-container {
        margin: 0;
    }
    
    .xx-xsmb-header {
        padding: 15px;
    }
    
    .xx-xsmb-icon,
    .xx-xsmb-icon-img {
        width: 28px !important;
        height: 28px !important;
    }
    
    .xx-xsmb-title-wrapper {
        gap: 10px !important;
    }
    
    .xx-xsmb-title {
        font-size: 18px !important;
        letter-spacing: 0.5px !important;
    }
    
    .xx-title-separator {
        font-size: 18px !important;
    }
    
    .xx-xsmb-date {
        font-size: 13px !important;
    }
    
    .xx-xsmb-date strong {
        font-size: 14px !important;
    }
    
    .xx-xsmb-countdown {
        font-size: 12px !important;
    }
    
    .xx-countdown-time {
        font-size: 14px !important;
    }
    
    .xx-xsmb-action {
        padding: 12px 15px;
    }
    
    .xx-xsmb-btn {
        padding: 10px 30px;
        font-size: 14px;
    }
    
    .xx-xsmb-results {
        padding: 15px !important;
    }
    
    .xx-prize-label {
        min-width: 50px !important;
        font-size: 14px !important;
        margin-right: 15px !important;
    }
    
    .xx-number-box {
        font-size: 20px !important;
    }
    
    .xx-number-box.xx-special {
        font-size: 26px !important;
    }
    
    .xx-loto-grid {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
        gap: 10px;
    }
    
    .xx-loto-ball {
        width: 60px;
        height: 60px;
        font-size: 18px;
    }
    
    .xx-loto-ball .xx-count {
        width: 22px;
        height: 22px;
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .xx-xsmb-header {
        padding: 12px;
    }
    
    .xx-xsmb-icon,
    .xx-xsmb-icon-img {
        width: 24px !important;
        height: 24px !important;
    }
    
    .xx-xsmb-title-wrapper {
        gap: 8px !important;
    }
    
    .xx-xsmb-title {
        font-size: 16px !important;
    }
    
    .xx-title-separator {
        font-size: 16px !important;
    }
    
    .xx-xsmb-date {
        font-size: 12px !important;
    }
    
    .xx-xsmb-date strong {
        font-size: 13px !important;
    }
    
    .xx-xsmb-countdown {
        font-size: 11px !important;
    }
    
    .xx-countdown-time {
        font-size: 13px !important;
        letter-spacing: 0.5px !important;
    }
    
    .xx-xsmb-btn {
        padding: 10px 24px;
        font-size: 13px;
        gap: 6px;
    }
    
    .xx-btn-icon {
        width: 16px;
        height: 16px;
    }
    
    .xx-xsmb-results {
        padding: 12px !important;
    }
    
    .xx-xsmb-prize-row {
        padding: 10px 0 !important;
    }
    
    .xx-prize-label {
        min-width: 40px !important;
        font-size: 13px !important;
        margin-right: 10px !important;
    }
    
    .xx-prize-numbers {
        gap: 8px !important;
    }
    
    .xx-number-box {
        font-size: 18px !important;
    }
    
    .xx-number-box.xx-special {
        font-size: 24px !important;
    }
    
    .xx-xsmb-statistics {
        padding: 20px 15px;
    }
    
    .xx-stats-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start !important;
    }
    
    .xx-stats-title {
        font-size: 16px;
    }
    
    .xx-copy-btn {
        font-size: 13px !important;
        padding: 6px 12px !important;
    }
    
    .xx-region-label {
        padding: 6px 16px;
        font-size: 13px;
    }
    
    .xx-loto-grid {
        grid-template-columns: repeat(auto-fill, minmax(55px, 1fr));
        gap: 8px;
    }
    
    .xx-loto-ball {
        width: 55px;
        height: 55px;
        font-size: 16px;
        border-width: 2px;
    }
    
    .xx-loto-ball .xx-count {
        width: 20px;
        height: 20px;
        font-size: 9px;
        top: -3px;
        right: -3px;
    }
}
