:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --background-noise: repeating-linear-gradient(45deg, rgba(0,0,0,0.02), rgba(0,0,0,0.02) 1px, transparent 1px, transparent 20px);
    --body-bg: var(--light-color);
    --container-bg: white;
    --text-color: var(--dark-color);
}

body.dark-mode {
    --body-bg: #1a1a1a;
    --container-bg: #2a2a2a;
    --text-color: var(--light-color);
    --dark-color: var(--light-color);
    --light-color: var(--dark-color);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: var(--body-bg);
    background-image: var(--background-noise);
    margin: 0;
    transition: background-color 0.3s ease;
}

.container {
    text-align: center;
    background-color: var(--container-bg);
    padding: 2rem 3rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1), 0 1px 8px rgba(0, 0, 0, 0.06);
    max-width: 90%;
    width: 500px;
    position: relative;
    transition: background-color 0.3s ease;
}

.theme-switch-wrapper {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    display: flex;
    align-items: center;
}

.theme-switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
}

input:checked + .slider {
    background-color: var(--primary-color);
}

input:focus + .slider {
    box-shadow: 0 0 1px var(--primary-color);
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}


h1 {
    color: var(--text-color);
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.lotto-numbers {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.number {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    font-size: 1.5rem;
    font-weight: bold;
    color: white;
    background-image: linear-gradient(145deg, var(--primary-color), var(--info-color));
    box-shadow: 0 4px 15px rgba(13, 110, 253, 0.4);
    transition: transform 0.3s ease;
}

.number:hover {
    transform: translateY(-5px) scale(1.05);
}

#generate-btn {
    font-size: 1.2rem;
    font-weight: bold;
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 50px;
    color: white;
    background-color: var(--success-color);
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(25, 135, 84, 0.3);
}

#generate-btn:hover, #generate-btn:focus {
    outline: none;
    background-color: #157347;
    box-shadow: 0 0 0 4px rgba(25, 135, 84, 0.5), 0 5px 20px rgba(25, 135, 84, 0.5);
}

/* Responsive Styles */
@media (max-width: 600px) {
    .container {
        padding: 1.5rem;
    }

    h1 {
        font-size: 2rem;
    }

    .lotto-numbers {
        gap: 0.5rem;
    }

    .number {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
    }

    #generate-btn {
        font-size: 1rem;
        padding: 0.7rem 1.5rem;
    }
}
