:root {
    --bg-color: #f0f2f5;
    --container-bg: #ffffff;
    --text-color: #333333;
    --accent-color: #1877f2;
    --button-bg: #42b72a;
    --button-hover: #36a420;
    --history-bg: #f0f2f5;
    --shadow-color: rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] {
    --bg-color: #18191a;
    --container-bg: #242526;
    --text-color: #e4e6eb;
    --accent-color: #2e89ff;
    --button-bg: #45bd62;
    --button-hover: #36a420;
    --history-bg: #3a3b3c;
    --shadow-color: rgba(0, 0, 0, 0.3);
}

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

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

.theme-toggle {
    position: absolute;
    top: 1rem;
    right: 1rem;
}

#theme-btn {
    background: none;
    border: 1px solid var(--text-color);
    color: var(--text-color);
    padding: 0.5rem;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.3s;
}

h1 {
    margin-top: 1rem;
    color: var(--accent-color);
}

.lotto-display {
    margin: 2rem 0;
}

.numbers {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.number {
    background-color: var(--accent-color);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    font-weight: bold;
    box-shadow: 0 2px 4px var(--shadow-color);
}

#generate-btn {
    background-color: var(--button-bg);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1rem;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

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

.history {
    margin-top: 2rem;
    text-align: left;
}

#history-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

#history-list li {
    background-color: var(--history-bg);
    padding: 0.5rem;
    border-radius: 5px;
    margin-bottom: 0.5rem;
    transition: background-color 0.3s;
}

.contact-form {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--history-bg);
    text-align: left;
}

.contact-form h2 {
    color: var(--accent-color);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
    color: var(--text-color);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.8rem;
    border-radius: 5px;
    border: 1px solid var(--history-bg);
    background-color: var(--bg-color);
    color: var(--text-color);
    font-size: 1rem;
    box-sizing: border-box;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

#submit-btn {
    background-color: var(--accent-color);
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
    transition: opacity 0.3s;
}

#submit-btn:hover {
    opacity: 0.9;
}

.ad-container {
    margin: 2rem 0;
    min-height: 100px;
    background-color: var(--history-bg);
    border-radius: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}
