/* Lottery Product Enhancement - Frontend Styles */

.lpe-widget-container {
    max-width: 100%;
    width: 100%;
    margin: 0;
    gap: 35px;
    display: flex;
    flex-direction: column;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Progress Section */
.lpe-progress-section {
    background: white;
    padding: 0px;
    margin-bottom: 0px;
}

.lpe-progress-bar {
    height: 30px;
    background: #ffffff;
    padding: 2px;
    border: 1px solid black;
    margin-bottom: 10px;
    border-radius: 25px;
    overflow: hidden;
    position: relative;
}

.lpe-progress-fill {
    height: 100%;
    background: #2d2d2d;
    border-radius: 25px;
    transition: width 0.5s ease;
    display: flex;
    align-items: center;
    padding: 0 20px;
    position: relative;
    min-width: 100px;
}

.lpe-progress-percentage {
    color: white;
    font-weight: 600;
    font-size: 12px;
    position: absolute;
    left: 20px;
    z-index: 2;
}

.lpe-progress-numbers {
    text-align: center;
    color: #2d2d2d;
    font-size: 12px;
    margin-top: 5px;
    display: block;
}

/* Price Display Section */
.lpe-ticket-price {
    padding: 15px 25px;
    font-size: 28px;
    font-weight: 500;
    font-family: 'Staatliches';
    line-height: 1;
    background: #f4f4f4;
    color: #2d2d2d;
    border-radius: 35px;
    margin: 0;
    width: fit-content;
    letter-spacing: 1px;
    text-align: center;
}

/* Main Widget */
.lpe-widget {
    background: #e8e8e8;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
}

/* Timer Section */
.lpe-timer {
    background: #2B9CFF;
    color: white;
    border-radius: 50px;
    padding: 15px 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    font-weight: 600;
    font-size: 18px;
    text-align: center;
}

/* Controls Container */
.lpe-controls {
    padding: 0;
}

/* Slider Section */
.lpe-slider-section {
    position: relative;
    margin-bottom: 30px;
}

.lpe-slider-label {
    position: absolute;
    top: -10px;
    left: 20px;
    background: #2d2d2d;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 18px;
    z-index: 3;
}

.lpe-slider-container {
    position: relative;
    padding: 20px 0;
}

.lpe-slider-track {
    position: relative;
    height: 20px;
    background: white;
    border-radius: 25px;
    overflow: visible;
}

.lpe-slider-fill {
    position: absolute;
    height: 100%;
    background: #E91E63;
    border-radius: 25px;
    width: 25%;
    transition: width 0.1s;
    pointer-events: none;
    z-index: 1;
}

.lpe-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 20px;
    background: transparent !important;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
    padding: 0;
    cursor: pointer;
    z-index: 3;
}

/* Remove all default track styling */
.lpe-slider::-webkit-slider-runnable-track {
    width: 100%;
    height: 20px;
    background: transparent !important;
    border: none !important;
    border-radius: 0;
    box-shadow: none !important;
}

.lpe-slider::-webkit-slider-track {
    width: 100%;
    height: 20px;
    background: transparent !important;
    border: none !important;
    border-radius: 0;
}

.lpe-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 40px;
    height: 40px;
    background: #2d2d2d url('/wp-content/uploads/2025/09/TicketIcon.svg') center/24px 24px no-repeat;
    border: 3px solid white;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    margin-top: -10px;
    position: relative;
}

/* Firefox */
.lpe-slider::-moz-range-track {
    width: 100%;
    height: 20px;
    background: transparent !important;
    border: none !important;
    border-radius: 0;
}

.lpe-slider::-moz-range-thumb {
    width: 34px;
    height: 34px;
    background: #2d2d2d url('/wp-content/uploads/2025/09/TicketIcon.svg') center/24px 24px no-repeat;
    border: 3px solid white;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.lpe-slider::-moz-range-progress {
    background: transparent !important;
    height: 0;
}

.lpe-slider:focus::-moz-range-track {
    background: transparent !important;
}

/* IE/Edge */
.lpe-slider::-ms-track {
    width: 100%;
    height: 20px;
    background: transparent !important;
    border-color: transparent !important;
    color: transparent !important;
    border-width: 0;
}

.lpe-slider::-ms-fill-lower {
    background: transparent !important;
    border: none !important;
}

.lpe-slider::-ms-fill-upper {
    background: transparent !important;
    border: none !important;
}

.lpe-slider::-ms-thumb {
    width: 40px;
    height: 40px;
    background: #2d2d2d url('/wp-content/uploads/2025/09/TicketIcon.svg') center/24px 24px no-repeat;
    border: 3px solid white;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

/* Price and Quantity Row - INLINE LAYOUT */
.lpe-price-qty-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    margin-bottom: 30px;
}

/* Price Container with Discount Display */
.lpe-price-container {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    position: relative;
}

/* Original Price (Strikethrough) */
.lpe-price-original {
    display: inline-flex;
    background: transparent;
    color: #999;
    padding: 5px 15px;
    font-size: 18px;
    font-weight: 500;
    text-decoration: line-through;
    text-align: center;
}

/* Discounted Price Display */
.lpe-price {
    display: inline-flex;
    background: #5a5a5a;
    color: white;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 32px;
    font-weight: 700;
    text-align: center;
}

/* Discount Badge */
.lpe-discount-badge {
    display: inline-flex;
    background: #4CAF50;
    color: white;
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: 700;
    text-align: center;
    margin-top: -5px;
}

/* Quantity Input */
.lpe-quantity {
    display: inline-flex;
    align-items: center;
    gap: 20px;
}

.lpe-qty-btn {
    width: 50px;
    height: 50px;
    background: white;
    border: 1px solid #000;
    border-radius: 50%;
    font-size: 24px;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.1s ease;
    color: #2d2d2d;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    
    /* 3D Shadow Effect similar to coreButton */
    box-shadow: 
        3px 3px 0 0 #000000,
        3px 3px 2px 1px rgba(0, 0, 0, 0.2);
}

.lpe-qty-btn:hover {
    transform: translate(1px, 1px);
    box-shadow: 
        2px 2px 0 0 #000000,
        2px 2px 2px 1px rgba(0, 0, 0, 0.2);
}

.lpe-qty-btn:active {
    transform: translate(2px, 2px);
    box-shadow: 
        1px 1px 0 0 #000000,
        1px 1px 1px 0 rgba(0, 0, 0, 0.2);
}

.lpe-qty-input {
    width: 60px;
    height: 50px;
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    border: none;
    background: white;
    border-radius: 10px;
    outline: none;
    color: #2d2d2d;
}

.lpe-qty-input:focus {
    box-shadow: 0 0 0 2px #2B9CFF;
}

/* Tier Buttons */
.lpe-tiers {
    display: flex;
    gap: 8px;
    margin-bottom: 25px;
    justify-content: space-between;
}

.lpe-tier-btn {
    flex: 1;
    background: white;
    border: 1px solid #000;
    border-radius: 15px;
    padding: 15px 5px;
    cursor: pointer;
    transition: all 0.1s ease;
    text-align: center;
    position: relative;
    
    /* 3D Shadow Effect */
    box-shadow: 
        3px 3px 0 0 #000000,
        3px 3px 2px 1px rgba(0, 0, 0, 0.1);
}

.lpe-tier-btn:hover {
    background: #2B9CFF;
    transform: translate(1px, 1px);
    box-shadow: 
        2px 2px 0 0 #000000,
        2px 2px 2px 1px rgba(0, 0, 0, 0.1);
}

.lpe-tier-btn:active {
    transform: translate(2px, 2px);
    box-shadow: 
        1px 1px 0 0 #000000,
        1px 1px 1px 0 rgba(0, 0, 0, 0.1);
}

.lpe-tier-btn:hover .lpe-tier-qty,
.lpe-tier-btn:hover .lpe-tier-label,
.lpe-tier-btn:hover .lpe-tier-discount {
    color: white;
}

.lpe-tier-qty {
    display: block;
    font-size: 20px;
    font-weight: 700;
    color: #2d2d2d;
    line-height: 1;
}

.lpe-tier-label {
    display: block;
    font-size: 11px;
    color: #666;
    text-transform: uppercase;
    margin-top: 4px;
    letter-spacing: 0.5px;
}

.lpe-tier-discount {
    display: block;
    font-size: 10px;
    color: #4CAF50;
    font-weight: 600;
    margin-top: 2px;
}

/* Add to Cart Button - Using coreButton styles */
.lpe-add-to-cart {
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
}

.lpe-add-to-cart.loading {
    background: #f0f0f0;
    border-color: #ccc;
    color: #999;
    pointer-events: none;
    box-shadow: none;
    transform: none;
}

.lpe-add-to-cart.success {
    background: #4CAF50;
    border-color: #4CAF50;
    color: white;
}

.lpe-cart-icon {
    width: 24px;
    height: 24px;
}

/* Free Postal Entry Button */
.lpe-postal-btn {
    width: 100%;
    padding: 14px;
    background: white;
    border: 2px solid #ddd;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.lpe-postal-btn:hover {
    background: #f9f9f9;
    border-color: #999;
    color: #2d2d2d;
}

/* Modal Styles */
.lpe-modal {
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    animation: lpe-fadeIn 0.3s;
}

.lpe-modal.show {
    display: flex;
}

.lpe-modal-content {
    background: white;
    border-radius: 20px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: lpe-slideUp 0.3s;
    padding: 30px;
}

.lpe-modal-close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 28px;
    font-weight: 300;
    color: #999;
    background: none;
    border: none;
    cursor: pointer;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lpe-modal-close:hover {
    color: #2d2d2d;
}

.lpe-modal-success {
    text-align: center;
    margin-bottom: 25px;
}

.lpe-modal-success svg {
    width: 60px;
    height: 60px;
    margin-bottom: 15px;
}

.lpe-modal-success h3 {
    font-size: 20px;
    color: #2d2d2d;
    margin: 0;
}

.lpe-modal-product {
    display: flex;
    gap: 20px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 15px;
    margin-bottom: 20px;
    align-items: center;
}

.lpe-modal-product img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 10px;
}

.lpe-modal-product-info {
    flex: 1;
}

.lpe-modal-product-info h4 {
    margin: 0 0 5px 0;
    font-size: 18px;
    color: #2d2d2d;
}

.lpe-modal-product-info p {
    margin: 5px 0;
    color: #666;
    font-size: 14px;
}

.lpe-modal-product-info .lpe-discount {
    color: #4CAF50;
    font-weight: 600;
}

.lpe-modal-total {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid #eee;
    margin-bottom: 20px;
}

.lpe-modal-total strong {
    font-size: 24px;
    color: #2d2d2d;
}

.lpe-modal-actions {
    display: flex;
    gap: 10px;
}

.lpe-modal-btn {
    flex: 1;
    padding: 14px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.lpe-btn-continue {
    background: white;
    border: 2px solid #ddd;
    color: #666;
}

.lpe-btn-continue:hover {
    background: #f9f9f9;
    border-color: #999;
    color: #2d2d2d;
}

.lpe-btn-view-cart {
    background: #FFD700;
    border: 2px solid #2d2d2d;
    color: #2d2d2d;
}

.lpe-btn-view-cart:hover {
    background: #FFC700;
}

/* Animations */
@keyframes lpe-fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes lpe-slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

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

.lpe-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(0,0,0,.1);
    border-top-color: #2d2d2d;
    border-radius: 50%;
    animation: lpe-spin 0.8s linear infinite;
}

/* Responsive */
@media (max-width: 600px) {
    .lpe-widget-container {
        margin: 10px;
    }
    
    .lpe-ticket-price {
        font-size: 24px;
        padding: 12px 20px;
    }
    
    .lpe-timer {
        font-size: 16px;
        padding: 12px 20px;
    }
    
    .lpe-slider-label {
        position: static;
        display: block;
        margin: 0 auto 10px;
        width: fit-content;
    }
    
    .lpe-price-qty-row {
        flex-direction: column;
        gap: 20px;
    }
    
    .lpe-price {
        font-size: 28px;
        padding: 12px 25px;
    }
    
    .lpe-tiers {
        flex-wrap: wrap;
    }
    
    .lpe-tier-btn {
        min-width: calc(50% - 4px);
        margin-bottom: 8px;
    }
    
    .lpe-modal-product {
        flex-direction: column;
        text-align: center;
    }
    
    .lpe-modal-actions {
        flex-direction: column;
    }
}

/* Utility Classes */
.lpe-hide {
    display: none !important;
}

.lpe-text-center {
    text-align: center;
}

.lpe-mt-20 {
    margin-top: 20px;
}

.lpe-mb-20 {
    margin-bottom: 20px;
}

/* New Quick Add Modal */
.lpe-modal-content-large {
    max-width: 600px;
    padding: 40px;
}

/* Widget inside modal adjustments */
.lpe-lottery-widget-modal .lpe-widget-container {
    margin: 0;
}

.lpe-lottery-widget-modal .lpe-widget {
    box-shadow: none;
}