body {
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: #1a1a1a;
    font-family: Arial, sans-serif;
}

.menu {
    text-align: center;
}

.title {
    color: #ffffff;
    font-size: 4em;
    text-transform: uppercase;
    margin-bottom: 1em;
    text-shadow: 
        0 1px 0 #ccc,
        0 2px 0 #c9c9c9,
        0 3px 0 #bbb,
        0 4px 0 #b9b9b9,
        0 5px 0 #aaa,
        0 6px 1px rgba(0,0,0,.1),
        0 0 5px rgba(0,0,0,.1),
        0 1px 3px rgba(0,0,0,.3),
        0 3px 5px rgba(0,0,0,.2),
        0 5px 10px rgba(0,0,0,.25),
        0 10px 10px rgba(0,0,0,.2),
        0 20px 20px rgba(0,0,0,.15);
}

.difficulty-options {
    display: flex;
    flex-direction: column;
    gap: 1em;
}

.menu-btn {
    padding: 1em 2em;
    font-size: 1.2em;
    border: none;
    border-radius: 8px;
    background: #4CAF50;
    color: white;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

.menu-btn:hover {
    transform: scale(1.05);
    background: #45a049;
}

.menu-btn:active {
    transform: scale(0.95);
}

.grid {
    display: grid;
    gap: 10px;
    padding: 20px;
}

.grid-3x3 {
    grid-template-columns: repeat(3, 100px);
}

.grid-4x4 {
    grid-template-columns: repeat(4, 85px);
}

.grid-5x5 {
    grid-template-columns: repeat(5, 70px);
}

.grid-6x6 {
    grid-template-columns: repeat(6, 60px);
}

.grid-8x8 {
    grid-template-columns: repeat(8, 45px);
}

.grid-20x20 {
    grid-template-columns: repeat(20, 20px);
}

.block {
    aspect-ratio: 1;
    width: 100%;
    background: #4CAF50;
    border-radius: 8px;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.block.odd {
    background: #4CAF50;
    position: relative;
}

.block.odd::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #ff4444;
    border-radius: 8px;
    z-index: -1;
}

.block.fade-out {
    opacity: 0;
    pointer-events: none;
}

.impossible-btn {
    background: #ff4444 !important;
}

.impossible-btn:hover {
    background: #ff0000 !important;
}

.block {
    position: relative;
}

.gift {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 20px;
    opacity: 0.08;
    user-select: none;
    z-index: 10;
    transition: opacity 0.2s;
    pointer-events: none;
}

.block.has-gift:hover .gift {
    opacity: 0.15;
}

.gift-notification {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    font-size: 1.5rem;
    color: white;
    background: rgba(128, 0, 128, 0.95);
    padding: 20px 40px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    z-index: 1001;
    opacity: 0;
    transition: opacity 0.5s ease-in-out, transform 0.5s ease-in-out;
    pointer-events: none;
}

.gift-notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}