/* Wheel of Fortune Plugin - Public Styles */

/* Popup Overlay */
.wof-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.wof-popup-overlay.wof-active {
    display: flex !important;
    opacity: 1;
    visibility: visible;
}

/* Popup Container */
.wof-popup {
    background: #ffffff;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 900px;
    width: 95%;
    max-height: 95vh;
    overflow: auto;
    position: relative;
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

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

/* Popup Header */
.wof-popup-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 15px 15px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.wof-popup-header h3 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

.wof-close-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 24px;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.wof-close-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Popup Content */
.wof-popup-content {
    padding: 30px;
    text-align: center;
}

.wof-step {
    display: none !important;
}

.wof-step.wof-active {
    display: block !important;
}

/* Email Form Styles */
#wof-email-form p {
    font-size: 18px;
    margin-bottom: 25px;
    color: #333;
}

#wof-email-input {
    width: 100%;
    padding: 15px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 16px;
    margin-bottom: 20px;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
}

#wof-email-input:focus {
    outline: none;
    border-color: #667eea;
}

/* Buttons */
.wof-btn-primary,
.wof-btn-secondary {
    padding: 15px 30px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
}

.wof-btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.wof-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.wof-btn-secondary {
    background: #f8f9fa;
    color: #333;
    border: 2px solid #e1e5e9;
}

.wof-btn-secondary:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

/* SVG Pie Chart Wheel */
.wof-wheel-wrapper {
    position: relative;
    width: 320px;
    height: 320px;
    margin: 0 auto 30px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.wof-wheel-container {
    position: relative;
    width: 320px;
    height: 320px;
}

.wof-wheel {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 4s cubic-bezier(0.23, 1, 0.32, 1);
}

.wof-wheel svg {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.wof-segment path {
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.wof-segment path:hover {
    opacity: 0.8;
}

.wof-segment text {
    pointer-events: none;
    user-select: none;
}

/* Pointer Shadow - now inline in SVG */

/* Pointer */
.wof-wheel-pointer {
    position: absolute;
    top: -5%;
    right: 0;
    left: 0;
    width: 40px;
    height: 60px;
    margin: auto;
    z-index: 4;
}

.wof-wheel-pointer svg,
.wof-wheel-pointer-shadow svg {
    transition: all 0.5s cubic-bezier(0.215, 0.61, 0.355, 1);
}

.wof-pointer-body {
    fill: #FFA1D9;
}

/* Loading Styles */
.wof-loading {
    text-align: center;
    padding: 20px;
}

.wof-loading p {
    font-size: 18px;
    color: #667eea;
    margin-bottom: 20px;
}

/* Spinner Animation */
.wof-loading::after {
    content: '';
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Result Popup Styles */
.wof-result-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 999999;
    display: none;
}

.wof-result-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1;
}

.wof-result-modal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    background: #ffffff;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 500px;
    z-index: 2;
    opacity: 0;
    transition: all 0.3s ease;
}

.wof-result-popup.active .wof-result-modal {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.wof-result-content {
    padding: 0;
}

.wof-result-header {
    padding: 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
    border-radius: 15px 15px 0 0;
}

.wof-result-header h4 {
    margin: 0 0 15px;
    font-size: 28px;
    font-weight: 600;
}

.wof-result-header p {
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
    opacity: 0.9;
}

/* Coupon Box Styles */
.wof-coupon-box {
    padding: 30px;
    border-bottom: 1px solid #e1e5e9;
}

.wof-coupon-header {
    margin-bottom: 15px;
}

.wof-coupon-header span {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.wof-coupon-display {
    display: flex;
    align-items: center;
    gap: 15px;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border: 2px dashed #e1e5e9;
}

#wof-coupon-text {
    font-family: monospace;
    font-size: 20px;
    font-weight: 600;
    color: #333;
    letter-spacing: 1px;
}

#wof-copy-coupon {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 15px;
    font-size: 14px;
    background: white;
    border: 1px solid #e1e5e9;
    color: #666;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-left: auto;
}

#wof-copy-coupon:hover {
    background: #f1f3f5;
    border-color: #adb5bd;
    color: #333;
}

#wof-copy-coupon svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
}

.wof-result-footer {
    padding: 20px 30px;
    text-align: center;
}

/* Animation Classes */
@keyframes resultFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

@keyframes resultFadeOut {
    from {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    to {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
}

.wof-result-popup.fade-in .wof-result-modal {
    animation: resultFadeIn 0.3s ease forwards;
}

.wof-result-popup.fade-out .wof-result-modal {
    animation: resultFadeOut 0.3s ease forwards;
}

/* Responsive Design */
@media (max-width: 480px) {
    .wof-popup {
        width: 95%;
        margin: 20px;
    }
    
    .wof-popup-content {
        padding: 20px;
    }
    
    .wof-wheel-wrapper {
        width: 250px;
        height: 250px;
    }
    
    .wof-segment {
        font-size: 12px;
    }
    
    .wof-coupon-display {
        flex-direction: column;
        text-align: center;
    }
    
    #wof-coupon-text {
        font-size: 16px;
    }
}

/* Animation Classes */
.wof-fade-in {
    animation: fadeIn 0.3s ease;
}

.wof-fade-out {
    animation: fadeOut 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeOut {
    from { opacity: 1; transform: translateY(0); }
    to { opacity: 0; transform: translateY(-20px); }
}

/* Flex Container for Side-by-Side Layout */
.wof-flex-container {
    display: flex;
    align-items: stretch;
    gap: 30px;
    min-height: 500px;
}

.wof-left-section {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
}

.wof-right-section {
    flex: 1;
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Email Form in Right Section */
#wof-email-form {
    text-align: left;
}

#wof-email-form h3 {
    font-size: 28px;
    margin: 0 0 15px;
    color: #333;
}

#wof-email-form p {
    font-size: 16px;
    line-height: 1.5;
    color: #666;
    margin-bottom: 25px;
}

/* Result Section */
#wof-result {
    margin-top: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    text-align: left;
}

.wof-result-content {
    padding: 20px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .wof-flex-container {
        flex-direction: column;
    }
    
    .wof-left-section,
    .wof-right-section {
        width: 100%;
    }
    
    .wof-popup {
        max-width: 95%;
        margin: 20px;
    }
    
    .wof-wheel-wrapper {
        width: 280px;
        height: 280px;
    }
    
    .wof-wheel-container {
        width: 280px;
        height: 280px;
    }
} 