:root {
    --background-color-light: #f0f2f5;
    --container-background-light: #fff;
    --text-color-light: #333;
    --button-background-light: #007bff;
    --button-hover-light: #0056b3;
    --input-background-light: #f8f8f8;
    --input-border-light: #ccc;

    --background-color-dark: #1a1a1a;
    --container-background-dark: #2c2c2c;
    --text-color-dark: #f0f2f5;
    --button-background-dark: #0056b3;
    --button-hover-dark: #007bff;
    --input-background-dark: #3a3a3a;
    --input-border-dark: #555;
}

body {
    font-family: 'Arial', sans-serif;
    background-color: var(--background-color-light);
    color: var(--text-color-light);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    transition: background-color 0.3s, color 0.3s;
}

body[data-theme="dark"] {
    --background-color-light: var(--background-color-dark);
    --container-background-light: var(--container-background-dark);
    --text-color-light: var(--text-color-dark);
    --button-background-light: var(--button-background-dark);
    --button-hover-light: var(--button-hover-dark);
    --input-background-light: var(--input-background-dark);
    --input-border-light: var(--input-border-dark);
}

.theme-switch-wrapper {
    position: absolute;
    top: 20px;
    right: 20px;
    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;
    border-radius: 34px;
}

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

input:checked + .slider {
    background-color: #2196F3;
}

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

.container {
    text-align: center;
    background-color: var(--container-background-light);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s;
}

h1 {
    margin-bottom: 30px;
    color: var(--text-color-light);
    transition: color 0.3s;
}

.lotto-numbers {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
    perspective: 1000px; /* For 3D effect if needed */
}

.lotto-numbers span {
    display: inline-block;
    width: 50px;
    height: 50px;
    line-height: 50px;
    margin: 0 10px;
    border-radius: 50%;
    background-color: #4CAF50;
    color: #fff;
    font-size: 24px;
    font-weight: bold;
    transform: scale(0);
    animation: pop-in 0.5s forwards;
}

@keyframes pop-in {
    from {
        transform: scale(0) rotateY(90deg);
        opacity: 0;
    }
    to {
        transform: scale(1) rotateY(0deg);
        opacity: 1;
    }
}

#generate-btn {
    padding: 15px 30px;
    font-size: 18px;
    border: none;
    border-radius: 10px;
    background-color: var(--button-background-light);
    color: #fff;
    cursor: pointer;
    transition: background-color 0.3s;
}

#generate-btn:hover {
    background-color: var(--button-hover-light);
}

/* Contact Form Styles */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 30px;
    text-align: left;
}

.contact-form label {
    font-weight: bold;
    color: var(--text-color-light);
}

.contact-form input[type="email"],
.contact-form textarea {
    padding: 10px;
    border: 1px solid var(--input-border-light);
    border-radius: 5px;
    font-size: 16px;
    background-color: var(--input-background-light);
    color: var(--text-color-light);
    transition: background-color 0.3s, border-color 0.3s, color 0.3s;
}

.contact-form input[type="email"]:focus,
.contact-form textarea:focus {
    border-color: var(--button-background-light);
    outline: none;
}

.contact-form button[type="submit"] {
    padding: 12px 20px;
    font-size: 16px;
    border: none;
    border-radius: 8px;
    background-color: #28a745; /* A distinct color for submit */
    color: #fff;
    cursor: pointer;
    transition: background-color 0.3s;
}

.contact-form button[type="submit"]:hover {
    background-color: #218838;
}

h2 {
    color: var(--text-color-light);
    margin-bottom: 20px;
    transition: color 0.3s;
}

@media (max-width: 768px) {
    body {
        align-items: flex-start;
    }

    .container {
        padding: 20px;
        width: 90%;
        margin-top: 50px;
    }

    h1 {
        font-size: 24px;
    }

    .lotto-numbers {
        flex-wrap: wrap;
    }

    .lotto-numbers span {
        width: 40px;
        height: 40px;
        line-height: 40px;
        font-size: 18px;
        margin: 5px;
    }

    #generate-btn {
        padding: 12px 25px;
        font-size: 16px;
    }
}
