/* v4-5.css - Royal Reels Casino Games Section */

.rr-games {
    color: var(--text-main);
    position: relative;
    overflow: hidden
}

/* Animated background pattern */
.rr-games::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(circle at 25% 25%, rgba(124, 58, 237, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 75% 75%, rgba(255, 215, 0, 0.03) 0%, transparent 40%);
    animation: rr-rotate-slow 30s linear infinite;
    pointer-events: none;
    z-index: 0
}

@keyframes rr-rotate-slow {
    from { transform: rotate(0deg) }
    to { transform: rotate(360deg) }
}

.rr-games .container {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-flow: column nowrap;
    flex-flow: column nowrap;
    gap: 20px;
    position: relative;
    z-index: 1
}

.rr-games .section__title,
.rr-games .text-block {
    max-width: 820px
}

/* Games grid */
.rr-games__list {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(3, 1fr);
    margin-top: 8px
}

/* Game card */
.rr-games__card {
    border-radius: 16px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    min-height: 256px;
    overflow: hidden;
    padding: 16px;
    width: 100%;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-flow: column nowrap;
    flex-flow: column nowrap;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    background: linear-gradient(135deg, rgba(26, 20, 37, 0.9) 0%, rgba(15, 10, 31, 0.95) 100%);
    color: #ffffff;
    gap: 8px;
    justify-content: space-between;
    position: relative;
    border: 1px solid rgba(255, 215, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    animation: rr-fade-scale-in 0.6s ease-out backwards;
    animation-delay: calc(var(--card-index, 0) * 0.1s)
}

@keyframes rr-fade-scale-in {
    from {
        opacity: 0;
        transform: scale(0.95)
    }
    to {
        opacity: 1;
        transform: scale(1)
    }
}

/* Gradient overlay for cards with background */
.rr-games__card:before {
    background: linear-gradient(
        270deg,
        rgba(15, 10, 31, 0) 0%,
        rgba(15, 10, 31, 0.7) 50%,
        rgba(15, 10, 31, 0.9) 100%
    );
    content: "";
    height: 100%;
    left: 0;
    position: absolute;
    top: 0;
    width: 100%;
    z-index: 1;
    transition: opacity 0.3s ease
}

/* Hover effects */
.rr-games__card:hover {
    transform: translateY(-8px);
    box-shadow: 
        0 20px 40px rgba(124, 58, 237, 0.3),
        0 0 0 2px rgba(255, 215, 0, 0.3);
    border-color: rgba(255, 215, 0, 0.3)
}

.rr-games__card:hover:before {
    opacity: 0.8
}

/* Premium badge for featured games */
.rr-games__card[data-featured="true"]::after {
    content: '👑 FEATURED';
    position: absolute;
    top: 16px;
    right: 16px;
    background: linear-gradient(135deg, #ffd700 0%, #fbbf24 100%);
    color: #0f0a1f;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    z-index: 2;
    animation: rr-shine 3s ease-in-out infinite
}

@keyframes rr-shine {
    0%, 100% { 
        box-shadow: 0 2px 8px rgba(255, 215, 0, 0.4)
    }
    50% { 
        box-shadow: 0 4px 16px rgba(255, 215, 0, 0.6)
    }
}

/* Cards without background image */
.rr-games__card:not(:has(.rr-games__card-bg)) {
    color: var(--card-text);
    background: 
        linear-gradient(135deg, rgba(124, 58, 237, 0.1) 0%, rgba(255, 215, 0, 0.05) 100%),
        linear-gradient(135deg, rgba(26, 20, 37, 0.95) 0%, rgba(15, 10, 31, 0.98) 100%)
}

.rr-games__card:not(:has(.rr-games__card-bg)):before {
    display: none
}

.rr-games__card:not(:has(.rr-games__card-bg)) .rr-games__card-info {
    max-width: unset
}

/* Background image */
.rr-games__card-bg {
    height: 100%;
    left: 0;
    position: absolute;
    top: 0;
    width: 100%;
    z-index: 0
}

.rr-games__card-bg__img {
    display: block;
    height: 100%;
    -o-object-fit: cover;
    object-fit: cover;
    width: 100%;
    transition: transform 0.4s ease;
    filter: brightness(0.8)
}

.rr-games__card:hover .rr-games__card-bg__img {
    transform: scale(1.1);
    filter: brightness(1)
}

/* Card content */
.rr-games__card-info {
    max-width: 220px;
    position: relative;
    z-index: 2
}

.rr-games__card-info__title {
    font-family: var(--font-2);
    font-size: 24px;
    font-weight: 600;
    line-height: 130%;
    margin-bottom: 8px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    background: linear-gradient(135deg, #ffffff 0%, #ffd700 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text
}

.rr-games__card-info__description {
    font-size: 16px;
    font-weight: 400;
    line-height: 150%;
    opacity: 0.95;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5)
}

/* Card buttons */
.rr-games__card-buttons {
    display: grid;
    gap: 8px;
    grid-template-columns: repeat(2, 1fr);
    position: relative;
    z-index: 2
}

.rr-games__card-buttons__item {
    padding: 10px 16px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.9) 0%, rgba(251, 191, 36, 0.9) 100%);
    color: #0f0a1f;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    cursor: pointer;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden
}

/* Primary button (first child) */
.rr-games__card-buttons__item:first-child {
    background: linear-gradient(135deg, #ffd700 0%, #fbbf24 100%);
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3)
}

/* Secondary button */
.rr-games__card-buttons__item:last-child {
    background: transparent;
    color: #ffd700;
    border: 1px solid rgba(255, 215, 0, 0.5)
}

/* Button hover effects */
.rr-games__card-buttons__item:hover {
    transform: translateY(-2px)
}

.rr-games__card-buttons__item:first-child:hover {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    box-shadow: 0 6px 16px rgba(255, 215, 0, 0.4)
}

.rr-games__card-buttons__item:last-child:hover {
    background: rgba(255, 215, 0, 0.1);
    border-color: #ffd700
}

/* Button shine effect */
.rr-games__card-buttons__item::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    transform: rotate(45deg) translateX(-100%);
    transition: transform 0.6s
}

.rr-games__card-buttons__item:hover::before {
    transform: rotate(45deg) translateX(100%)
}

/* Lists inside cards */
.rr-games__card ol,
.rr-games__card ul {
    list-style: none;
    padding: 8px 0
}

.rr-games__card li {
    padding: 4px 0;
    padding-left: 20px;
    position: relative;
    color: rgba(255, 255, 255, 0.9)
}

.rr-games__card li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #ffd700;
    font-weight: bold
}

/* Responsive Design */
@media (max-width: 1000px) {
    .rr-games__list {
        grid-template-columns: repeat(2, 1fr)
    }
}

@media (max-width: 768px) {
    .rr-games .container {
        gap: 16px
    }
    
    .rr-games__card {
        min-height: 220px
    }
    
    .rr-games__card-info__title {
        font-size: 20px;
        font-weight: 600;
        line-height: 140%
    }
    
    .rr-games__card-info__description {
        font-size: 14px
    }
    
    .rr-games__card-buttons__item {
        padding: 8px 12px;
        font-size: 12px
    }
}

@media (max-width: 600px) {
    .rr-games__list {
        grid-template-columns: repeat(1, 1fr)
    }
    
    .rr-games__card {
        min-height: 200px
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    .rr-games::before,
    .rr-games__card,
    .rr-games__card[data-featured="true"]::after {
        animation: none
    }
    
    .rr-games__card,
    .rr-games__card-bg__img,
    .rr-games__card-buttons__item {
        transition: none
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .rr-games__card {
        border-width: 2px
    }
    
    .rr-games__card-buttons__item {
        border-width: 2px
    }
}