/**
 * Prize Slider Styles
 * For hero card image sliders
 */

/* Slider Container */
.prize-slider-container {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: inherit;
}

.prize-slider-track {
    display: flex;
    width: 100%;
    height: 100%;
    position: relative;
    /* Remove transform transition for fade effect */
}

.prize-slider-slide {
    flex: 0 0 100%;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
}

.prize-slider-slide.active {
    opacity: 1;
    pointer-events: auto;
    z-index: 1;
}

.prize-slider-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* iPhone prize specific: use contain with white background, smaller centered images */
.prize-slider-container[data-prize-type="iphone"] {
    background: #ffffff;
}

.prize-slider-container[data-prize-type="iphone"] .prize-slider-slide {
    background: #ffffff;
    padding: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.prize-slider-container[data-prize-type="iphone"] .prize-slider-slide img {
    object-fit: contain;
    object-position: center;
    max-width: 720px;
    max-height: 520px;
    width: auto;
    height: auto;
    margin: auto;
    display: block;
}

/* Slider Buttons */
.prize-slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    font-size: 24px;
    font-weight: bold;
    color: #1a1a1a;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    user-select: none;
}

.prize-slider-btn:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.prize-slider-btn:active {
    transform: translateY(-50%) scale(0.95);
}

.prize-slider-prev {
    left: 1rem;
}

.prize-slider-next {
    right: 1rem;
}

/* Slider Dots */
.prize-slider-dots {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
    z-index: 10;
}

.prize-slider-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: 2px solid rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.prize-slider-dot:hover {
    background: rgba(255, 255, 255, 0.8);
    transform: scale(1.2);
}

.prize-slider-dot.active {
    background: white;
    border-color: white;
    width: 24px;
    border-radius: 5px;
}

/* Hero Card Styles */
.prize-hero-card {
    width: 100%;
    border-radius: 20px;
    overflow: visible; /* Allow countdown to be visible */
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
    position: relative; /* For countdown positioning */
}

/* Clip wrapper content but allow countdown */
.prize-hero-card .prize-hero-wrapper {
    overflow: hidden;
    border-radius: 20px; /* Match card border radius */
}

.prize-hero-card-mini {
    width: 100%;
    border-radius: 20px;
    overflow: visible;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.prize-hero-card-mini:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(233, 30, 99, 0.2);
}

.prize-hero-wrapper {
    position: relative;
    width: 100%;
    overflow: visible; /* Allow full card content to be visible */
}

.prize-hero-full {
    height: clamp(500px, 70vh, 800px);
    min-height: 500px;
}

.prize-hero-mini {
    height: clamp(550px, 60vh, 650px);
    min-height: 550px;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: row;
    align-items: stretch;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    background: #1a1a1a;
}

.prize-hero-image-wrapper,
.prize-slider-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Standardized image wrapper for mini cards - Horizontal layout */
.prize-hero-card-mini .prize-hero-image-wrapper,
.prize-hero-card-mini .prize-slider-container {
    position: relative;
    width: 50%;
    height: 100%;
    overflow: hidden;
    border-radius: 20px 0 0 20px;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    flex-shrink: 0;
}

.prize-hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
    filter: brightness(1.08) contrast(1.12) saturate(1.08);
}

/* For packshot-style images (products) */
.prize-hero-card-mini .prize-hero-image-wrapper.is-packshot .prize-hero-image,
.prize-hero-card-mini .prize-slider-container.is-packshot .prize-hero-image {
    object-fit: contain;
    padding: 10px;
}

/* For packshots that must not crop */
.prize-hero-card-mini .prize-hero-image-wrapper.is-packshot,
.prize-hero-card-mini .prize-slider-container.is-packshot {
    background: transparent;
    padding: 0;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
}

.prize-hero-card-mini .prize-hero-image-wrapper.is-packshot .prize-hero-image,
.prize-hero-card-mini .prize-slider-container.is-packshot .prize-hero-image {
    object-fit: cover;
    width: 100%;
    height: 100%;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
    filter: brightness(1.05) contrast(1.1);
}

/* Prize overlay on image side */
.prize-overlay-on-image {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.75) 50%, rgba(0,0,0,0.98) 100%);
    padding: 1.2rem;
    z-index: 5;
    border-radius: 0 0 18px 0;
}

.prize-value-overlay {
    font-size: 2.5rem;
    font-weight: 900;
    color: #ffffff !important;
    line-height: 1.1;
    text-shadow: 0 3px 15px rgba(233, 30, 99, 1), 0 0 20px rgba(233, 30, 99, 0.8);
    letter-spacing: -0.5px;
    margin: 0;
}

.prize-title-overlay {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 1) !important;
    margin-top: 0.4rem;
    font-weight: 800;
    line-height: 1.2;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9);
}

/* Game video preview */
.game-video-preview {
    border-radius: 8px;
    overflow: hidden;
    background: #000;
    border: 2px solid rgba(233, 30, 99, 0.4);
    position: relative;
    aspect-ratio: 16/9;
    min-height: 120px;
}

.game-video-preview video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.game-video-preview:hover {
    border-color: rgba(233, 30, 99, 0.7);
    transform: scale(1.02);
    transition: all 0.3s ease;
}

.prize-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 15%;
    background: linear-gradient(
        180deg,
        transparent 0%,
        rgba(0, 0, 0, 0.05) 50%,
        rgba(0, 0, 0, 0.1) 100%
    );
    z-index: 1;
    pointer-events: none;
    bottom: auto;
}

/* Full-bleed hero for main prize (not mini) */
.prize-hero-fullbleed {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    border-radius: 20px;
    overflow: hidden; /* Keep countdown inside */
}

/* Overlay gradient for full-bleed hero text readability */
.prize-hero-overlay-fullbleed {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.35) 0%,
        rgba(0, 0, 0, 0.45) 50%,
        rgba(0, 0, 0, 0.55) 100%
    );
    z-index: 1;
    pointer-events: none;
}

/* Content for full-bleed hero */
.prize-hero-content-fullbleed {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    padding: 3rem;
    max-width: 900px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.prize-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    padding: 2rem;
    max-width: 800px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.prize-hero-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

.prize-hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 900;
    margin-bottom: 0.5rem;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    line-height: 1.1;
}

.prize-hero-value {
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    font-weight: 800;
    margin-bottom: 2rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.prize-hero-cta-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    margin-bottom: 2rem;
}

.btn-play-now-hero {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #E91E63 0%, #2196F3 100%);
    color: white;
    padding: 0.75rem 1.5rem;
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    font-weight: 600;
    border-radius: 50px;
    text-decoration: none;
    box-shadow: 0 8px 20px rgba(233, 30, 99, 0.4);
    transition: all 0.3s ease;
    text-align: center;
    position: relative;
    overflow: hidden;
    z-index: 0;
}

.btn-play-now-hero > * {
    position: relative;
    z-index: 2;
}

.btn-play-now-hero:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 12px 25px rgba(233, 30, 99, 0.5);
}

/* Shimmer animation for play buttons on mobile */
@keyframes shimmer {
    0% {
        transform: translateX(-100%) translateY(-50%) skewX(-20deg);
    }
    100% {
        transform: translateX(200%) translateY(-50%) skewX(-20deg);
    }
}

.btn-play-now-hero::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 50%;
    height: 200%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.5),
        transparent
    );
    transform: translateX(-100%) translateY(-50%) skewX(-20deg);
    animation: shimmer 2.5s infinite;
    pointer-events: none;
    z-index: 1;
    display: none; /* Hidden by default, show on mobile */
}

@media (max-width: 768px) {
    .btn-play-now-hero::before {
        display: block;
        animation: shimmer 2s infinite;
        background: linear-gradient(
            90deg,
            transparent,
            rgba(255, 255, 255, 0.7),
            transparent
        );
    }
}

@media (max-width: 480px) {
    .btn-play-now-hero::before {
        animation: shimmer 1.8s infinite;
        background: linear-gradient(
            90deg,
            transparent,
            rgba(255, 255, 255, 0.8),
            transparent
        );
    }
}

/* Play icon inside hero play button - aligned with text */
.btn-play-now-hero .play-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1em;
    height: 1em;
    font-size: 0.7em;
    line-height: 1;
    vertical-align: middle;
    margin-bottom: 0.08em;
}

.btn-how-it-works-hero {
    background: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.8);
    padding: 0.75rem 1.5rem;
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-how-it-works-hero:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: white;
}

.prize-hero-progress {
    width: 100%;
    max-width: 500px;
    margin-bottom: 1rem;
}

.prize-hero-progress-text {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.prize-hero-progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    overflow: hidden;
}

.prize-hero-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4CAF50 0%, #8BC34A 100%);
    transition: width 0.5s ease;
    border-radius: 10px;
}

.prize-hero-meta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
    font-size: 0.85rem;
    opacity: 0.9;
}

.prize-meta-item {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-weight: 600;
}

.prize-hero-countdown {
    position: absolute;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 10;
    display: flex;
    gap: 0.75rem;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 0.75rem 1.25rem;
    color: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    align-items: center;
}


.prize-hero-countdown .countdown-label {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    opacity: 0.8;
    margin-right: 0.5rem;
}

.prize-hero-countdown .countdown-blocks {
    display: flex;
    gap: 0.75rem;
}

.prize-hero-countdown .countdown-block {
    text-align: center;
    line-height: 1;
}

.prize-hero-countdown .countdown-value {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    font-weight: 800;
    color: #4CAF50;
    display: block;
}

.prize-hero-countdown .countdown-unit {
    font-size: 0.7rem;
    opacity: 0.7;
    text-transform: uppercase;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .prize-hero-full {
        height: clamp(400px, 60vh, 600px);
        min-height: 400px;
    }
    
    .prize-hero-mini {
        flex-direction: column !important;
        height: auto !important;
        min-height: auto !important;
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
        align-items: stretch !important;
    }
    
    /* Stack vertically on mobile - image on top, content below */
    .prize-hero-card-mini .prize-hero-image-wrapper,
    .prize-hero-card-mini .prize-slider-container {
        width: 100% !important;
        height: 250px !important;
        border-radius: 20px 20px 0 0 !important;
        position: relative !important;
        flex-shrink: 0 !important;
        flex: none !important;
    }
    
    .prize-hero-content-game {
        width: 100% !important;
        max-width: 100% !important;
        border-radius: 0 0 20px 20px !important;
        border-left: none !important;
        border-top: 4px solid #E91E63 !important;
        padding: 1rem 1.25rem !important;
        position: relative !important;
        flex: 1 1 auto !important;
        min-height: auto !important;
        justify-content: flex-start !important;
        margin: 0 !important;
    }
    
    .prize-overlay-on-image {
        padding: 1rem !important;
    }
    
    .prize-value-overlay {
        font-size: 2rem !important;
    }
    
    .prize-title-overlay {
        font-size: 1rem !important;
    }
    
    /* Ensure proper alignment on mobile */
    .prize-hero-card-mini {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    /* Fix any inline width styles on mobile - override inline styles */
    .prize-hero-card-mini > *,
    .prize-hero-card-mini .prize-hero-image-wrapper[style*="width"],
    .prize-hero-card-mini .prize-hero-content-game[style*="width"] {
        max-width: 100% !important;
    }
    
    /* Force vertical stacking on mobile */
    .prize-hero-mini[style*="flex-direction"] {
        flex-direction: column !important;
    }
    
    /* Override inline width: 50% styles on mobile */
    .prize-hero-card-mini .prize-hero-image-wrapper[style*="50%"],
    .prize-hero-card-mini .prize-hero-content-game[style*="50%"] {
        width: 100% !important;
        flex: none !important;
    }
    
    .prize-hero-content-game .game-header {
        margin-bottom: 0.5rem !important;
    }
    
    .prize-hero-content-game .game-icon-large {
        font-size: 1.6rem !important;
        margin-bottom: 0.3rem !important;
    }
    
    .prize-hero-content-game .game-title {
        font-size: 1.1rem !important;
        margin-bottom: 0.3rem !important;
    }
    
    .prize-hero-content-game .game-description {
        font-size: 0.75rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    .prize-hero-content-game .game-video-preview {
        margin-bottom: 0.5rem !important;
        aspect-ratio: 16/9 !important;
    }
    
    .prize-hero-content-game .game-stats {
        margin-bottom: 0.5rem !important;
        gap: 0.5rem !important;
    }
    
    .prize-hero-content-game .game-stats > div {
        padding: 0.6rem 0.5rem !important;
    }
    
    .prize-hero-content-game .game-stats > div > div:first-child {
        font-size: 0.65rem !important;
    }
    
    .prize-hero-content-game .game-stats > div > div:last-child {
        font-size: 1.2rem !important;
    }
    
    .prize-hero-content-game .game-leaderboard {
        max-height: 160px !important;
        margin-bottom: 0.5rem !important;
        padding: 0.4rem !important;
    }
    
    .prize-hero-content-game .game-leaderboard > div:first-child {
        font-size: 0.7rem !important;
        padding: 0.3rem !important;
    }
    
    .prize-hero-content-game .game-leaderboard > div:last-child {
        font-size: 0.65rem !important;
    }
    
    .prize-hero-content-game .btn-play-now-hero {
        padding: 0.75rem 1.5rem !important;
        font-size: 0.9rem !important;
        width: 100% !important;
        max-width: 100% !important;
        display: block !important;
        margin: 0.5rem 0 0 0 !important;
    }
    
    /* Override inline width: 50% styles on mobile - use attribute selector */
    .prize-hero-card-mini .prize-hero-image-wrapper[style*="width"],
    .prize-hero-card-mini .prize-hero-content-game[style*="width"] {
        width: 100% !important;
        flex: none !important;
    }
    
    /* Ensure proper card structure on mobile */
    .prize-hero-mini {
        display: flex !important;
        flex-direction: column !important;
    }
    
    /* Fix any alignment issues */
    .prize-hero-card-mini {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
    }
    
    /* Force override inline styles on mobile */
    .prize-hero-mini .prize-hero-image-wrapper,
    .prize-hero-mini .prize-slider-container {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .prize-hero-mini .prize-hero-content-game {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .prize-slider-btn {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .prize-slider-prev {
        left: 0.5rem;
    }
    
    .prize-slider-next {
        right: 0.5rem;
    }
    
    .prize-hero-countdown {
        bottom: 1rem;
        right: 1rem;
        padding: 0.5rem 1rem;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .prize-hero-countdown .countdown-label {
        display: none;
    }
    
    .prize-hero-meta {
        font-size: 0.75rem;
        gap: 0.5rem;
    }
    
    /* Fix button alignment on mobile */
    .prize-hero-content-game .btn-play-now {
        width: 100% !important;
        margin: 0.5rem 0 0 0 !important;
        padding: 0.875rem 1.5rem !important;
        font-size: 0.95rem !important;
        text-align: center !important;
        display: block !important;
    }
    
    /* Ensure proper spacing and alignment */
    .prize-hero-content-game > * {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Fix any overflow issues */
    .prize-hero-card-mini {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
    }
}

@media (max-width: 480px) {
    .prize-hero-mini {
        border-radius: 15px !important;
    }
    
    .prize-hero-card-mini .prize-hero-image-wrapper,
    .prize-hero-card-mini .prize-slider-container {
        height: 200px !important;
        border-radius: 15px 15px 0 0 !important;
    }
    
    .prize-hero-content-game {
        border-radius: 0 0 15px 15px !important;
        padding: 0.875rem 1rem !important;
    }
    
    .prize-value-overlay {
        font-size: 1.75rem !important;
    }
    
    .prize-title-overlay {
        font-size: 0.9rem !important;
    }
    
    .prize-hero-content-game .game-title {
        font-size: 1rem !important;
    }
    
    .prize-hero-content-game .game-description {
        font-size: 0.7rem !important;
    }
    
    .prize-hero-content-game .game-stats {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.4rem !important;
    }
    
    .prize-hero-content-game .game-stats > div {
        padding: 0.5rem 0.4rem !important;
    }
    
    .prize-hero-content-game .game-stats > div > div:last-child {
        font-size: 1.1rem !important;
    }
}

