.wheel-modal {
    display: none;
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.7);
    overflow-y: auto;
}

.wheel-modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 48px;
    border-radius: 15px;
    width: 90%;
    max-width: 1200px;
    position: relative;
    animation: modalFadeIn 0.3s;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}

.wheel-close {
    position: absolute;
    right: 20px;
    top: 15px;
    color: #666;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    width: 30px;
    height: 30px;
    line-height: 30px;
    text-align: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.wheel-close:hover {
    color: #333;
    background-color: rgba(0,0,0,0.1);
}

@keyframes modalFadeIn {
    from { 
        opacity: 0; 
        transform: translateY(-30px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

#wheel-of-fortune-container {
    margin: 0 auto;
    background: #fff;
    display: flex;
    gap: 48px;
}

#wheel-wrapper {
    position: relative;
    width: 480px;
    height: 480px;
}

.wheel-subinfo p {
    font-size: 40px;
    margin-bottom: 16px;
    line-height: 1.1;
    font-weight: 700;
    margin-top: 0;
}

.wheel-info {
    display: flex;
    flex-direction: column;
    gap: 64px;
    justify-content: center;
}

.wheel-info button, .wheel-result_container button {
    width: 400px;
}

.wheel-subinfo p > span {
    color: #FF3825;
}


#wheel {
    position: relative;
    width: 480px;
    height: 480px;
    border-radius: 50%;
    border: 10px solid #333;
    overflow: hidden;
    background: transparent;
    transition: transform 4s cubic-bezier(0.17, 0.67, 0.12, 0.99);
    box-shadow: 0 0 20px rgba(0,0,0,0.2);
}

.wheel-segment {
    position: absolute;
    width: 50%;
    height: 50%;
    top: 0;
    left: 50%;
    transform-origin: 0% 100%;
    background: var(--segment-color);
    overflow: hidden;
    clip-path: polygon(34.51% -14.64%, 116.2% 67.97%, 2.94% 99.48%);
}

.segment-image {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) rotate(calc(-1 * var(--segment-angle) / 2));
    width: 120px;
    height: 120px;
    object-fit: cover;
    z-index: 10;
}

/* Центральный круг */
#wheel::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background: #333;
    border: 4px solid #fff;
    border-radius: 50%;
    z-index: 20;
}


#wheel-pointer {
    position: absolute;
    left: 50%;
    top: -10px;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-top: 30px solid #080808;
    z-index: 30;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

#spin-wheel, .wheel-result_container button {
    padding: 20px 30px;
    font-size: 20px;
    background: #FF3825;
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
}

#spin-wheel:hover, .wheel-result_container button:hover {
    background: #c0392b;
    transform: translateY(-2px);
}

#spin-wheel:disabled {
    background: #cccccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.wheel-result {
    background: #fff;
    border-radius: 10px;
    display: none;
    animation: fadeIn 0.5s;
}

.wheel-result_container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 64px;
}

.wheel-result_container .wheel-result_subinfo > div {
    color: #080808;
    font-variant-numeric: lining-nums proportional-nums;
    font-family: Raleway;
    font-size: 40px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
}

.wheel-result_container .wheel-result_subinfo > div > p {
    color: #FF3825;
    margin-top: 0;
    margin-bottom: 16px;
}

.wheel-result.show {
    display: flex;
    gap: 48px;
}

.wheel-result img {
    max-width: 480px;
    height: auto;
    border-radius: 240px;
    background: var(--Background-Gray-Pastel, #F7F7FA);
    box-shadow: 0px 0px 20px 0px rgba(0, 0, 0, 0.20);
}

@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(10px);
    }
    to { 
        opacity: 1; 
        transform: translateY(0);
    }
}

/* Адаптивность для мобильных устройств */
@media screen and (max-width: 768px) {
    .wheel-info button, .wheel-result_container button {
        width: 100%;
    }
    
    .wheel-modal-content {
        margin: 10% auto;
        padding: 48px 32px;
        width: 95%;
    }

    .wheel-result_container, .wheel-info {
        gap: 24px;
    }
    
    #wheel-of-fortune-container {
        flex-direction: column;
        gap: 24px;
        text-align: center;
    }

    .wheel-subinfo p, .wheel-result_container .wheel-result_subinfo > div {
        font-size: 28px;
    }

    #spin-wheel, .wheel-result_container button {
        padding: 16px 32px;
        font-size: 16px;
    }
    
    .wheel-subinfo span, .wheel-result_subinfo .wheel-result_subinfo p {
        font-size: 14px;
    }

    .wheel-result.show {
        flex-direction: column;
        gap: 24px;
    }

    #spin-wheel {
        width: 100%;
    }

    #wheel-wrapper {
        width: 320px;
        height: 320px;
    }

    #wheel {
        width: 320px;
        height: 320px;
        border-width: 8px;
    }

    .segment-image {
        width: 50px;
        height: 50px;
    }

    #wheel::after {
        width: 35px;
        height: 35px;
    }

    #spin-wheel {
        padding: 10px 25px;
        font-size: 16px;
    }

    #wheel-pointer {
        top: -8px;
        border-left: 16px solid transparent;
        border-right: 16px solid transparent;
        border-top: 25px solid #e74c3c;
    }
} 