:root {
    --background-start: #0f2027;
    --background-end: #203a43;
    --container-bg: rgba(0, 0, 0, 0.3);
    --primary-color: #2c5364;
    --secondary-color: #00a8c5;
    --text-color: #ffffff;
    --shadow-color: rgba(0, 0, 0, 0.5);
    --glow-color: rgba(0, 168, 197, 0.7);
    --ball-text: #ffffff;
}

body.light-mode {
    --background-start: #f5f7fa;
    --background-end: #c3cfe2;
    --container-bg: rgba(255, 255, 255, 0.8);
    --primary-color: #4facfe;
    --secondary-color: #00f2fe;
    --text-color: #333333;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --glow-color: rgba(79, 172, 254, 0.4);
    --ball-text: #ffffff;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    background: linear-gradient(45deg, var(--background-start), var(--background-end));
    color: var(--text-color);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    transition: background 0.5s ease, color 0.5s ease;
    padding: 20px;
    box-sizing: border-box;
}

.container {
    text-align: center;
    background: var(--container-bg);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 35px var(--shadow-color);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    max-width: 600px;
    width: 100%;
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px var(--shadow-color);
}

.theme-switch {
    position: fixed;
    top: 20px;
    right: 20px;
}

#theme-toggle {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.results-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.lotto-row {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.lotto-ball {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--ball-text);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    opacity: 0;
}

#generator-btn {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 15px var(--glow-color);
}

#generator-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 20px var(--glow-color);
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.5); }
    to { opacity: 1; transform: scale(1); }
}

@media (max-width: 500px) {
    .lotto-ball {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
    .lotto-row {
        gap: 5px;
    }
}
