/* Spin Wheel Popup Styles */
.spin-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.spin-popup-overlay.active {
    opacity: 1;
}

.spin-popup-container {
    background-color: #fff;
    width: 90%;
    max-width: 450px;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
}

.spin-popup-overlay.active .spin-popup-container {
    transform: scale(1);
}

.spin-close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    background: transparent;
    border: none;
    font-size: 28px;
    color: #666;
    cursor: pointer;
    z-index: 10;
    transition: color 0.2s;
}

.spin-close-btn:hover {
    color: #000;
}

.spin-popup-content {
    padding: 30px 20px;
    text-align: center;
}

.spin-popup-content h2 {
    color: var(--primary);
    font-size: 2rem;
    margin-bottom: 10px;
    font-family: var(--font-serif);
}

.spin-popup-content p {
    color: #555;
    margin-bottom: 20px;
}

/* Wheel Wrapper */
.spin-wheel-wrapper {
    position: relative;
    width: 300px;
    height: 300px;
    margin: 0 auto 30px;
}

#spinCanvas {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(0,0,0,0.1);
    /* The transition will be handled via JS for smoother easing, but CSS fallback here */
    transition: transform 5s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.spin-pointer {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 30px;
    background-color: var(--dark);
    clip-path: polygon(50% 100%, 0 0, 100% 0);
    z-index: 5;
    filter: drop-shadow(0 2px 2px rgba(0,0,0,0.2));
}

.spin-wheel-wrapper::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background-color: #fff;
    border: 4px solid var(--primary);
    border-radius: 50%;
    z-index: 4;
}
