
@layer base, components, utilities;

@layer base {
    :root {
        --bg-color: #f0f2f5;
        --container-bg: #ffffff;
        --text-color: #333333;
        --placeholder-bg: #e9ecef;
        --placeholder-text: #495057;
        --shadow: rgba(0, 0, 0, 0.1);
        --accent-gradient: linear-gradient(45deg, #FFC796, #FF6B99);
        --body-bg: linear-gradient(45deg, #FFC796, #FF6B99);
    }

    [data-theme="dark"] {
        --bg-color: #1a1a1a;
        --container-bg: #2d2d2d;
        --text-color: #f0f2f5;
        --placeholder-bg: #3d3d3d;
        --placeholder-text: #e0e0e0;
        --shadow: rgba(0, 0, 0, 0.5);
        --body-bg: linear-gradient(45deg, #2c3e50, #000000);
    }

    body {
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
        background: var(--body-bg);
        display: flex;
        justify-content: center;
        align-items: center;
        height: 100vh;
        margin: 0;
        transition: background 0.3s ease;
    }
}

@layer components {
    .container {
        position: relative;
        text-align: center;
        background-color: var(--container-bg);
        padding: 40px;
        border-radius: 15px;
        box-shadow: 0 10px 30px var(--shadow);
        transition: transform 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
    }

    .container:hover {
        transform: translateY(-5px);
    }

    h1 {
        color: var(--text-color);
        font-size: 2.5em;
        margin-bottom: 30px;
        transition: color 0.3s ease;
    }

    .lotto-numbers {
        display: flex;
        justify-content: center;
        gap: 15px;
        margin-bottom: 40px;
    }

    .number-placeholder {
        width: 60px;
        height: 60px;
        background-color: var(--placeholder-bg);
        border-radius: 50%;
        display: flex;
        justify-content: center;
        align-items: center;
        font-size: 1.8em;
        font-weight: bold;
        color: var(--placeholder-text);
        box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.06);
        transition: background-color 0.3s ease, color 0.3s ease;
    }

    #generate-btn {
        background: var(--accent-gradient);
        color: #ffffff;
        border: none;
        padding: 15px 30px;
        font-size: 1.2em;
        border-radius: 50px;
        cursor: pointer;
        transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    }

    #generate-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
    }

    #generate-btn:active {
        transform: translateY(1px);
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    }

    .theme-toggle {
        position: absolute;
        top: 20px;
        right: 20px;
        background: none;
        border: none;
        font-size: 1.5rem;
        cursor: pointer;
        padding: 5px;
        border-radius: 50%;
        transition: background-color 0.2s;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .theme-toggle:hover {
        background-color: rgba(0, 0, 0, 0.05);
    }

    [data-theme="dark"] .theme-toggle:hover {
        background-color: rgba(255, 255, 255, 0.1);
    }
}
