/* Дополнительные семантические улучшения для Mellstroy Casino */
/* Этот файл расширяет существующие стили, не заменяя их */

/* ========== СЕМАНТИЧЕСКИЕ DATA-АТРИБУТЫ ========== */
[data-mellstroy-casino] {
    position: relative;
}

[data-mellstroy-brand="official"] {
    /* Брендированные элементы логотипа */
}

[data-mellstroy-game-id] {
    /* Семантическая маркировка игр */
}

[data-mellstroy-promo-id] {
    /* Семантическая маркировка промо */
}

/* ========== УЛУЧШЕНИЯ ДОСТУПНОСТИ ========== */
.mellstroy-casino-popular-game {
    position: relative;
}

.mellstroy-casino-popular-game::after {
    content: "🔥 ПОПУЛЯРНОЕ";
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #FF6B00, #FF8C00);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 10;
}

.mellstroy-casino-new-game {
    position: relative;
}

.mellstroy-casino-new-game::after {
    content: "✨ НОВИНКА";
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #9400D3, #8A2BE2);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 10;
}

.mellstroy-casino-search-hidden {
    opacity: 0.3;
    transform: scale(0.95);
    transition: all 0.3s ease;
}

/* ========== МОДАЛЬНЫЕ ОКНА MELLSTROY CASINO ========== */
.mellstroy-casino-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mellstroy-casino-modal.show {
    opacity: 1;
    visibility: visible;
}

.mellstroy-casino-modal-content {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.95), rgba(255, 215, 0, 0.1));
    border-radius: 16px;
    border: 2px solid rgba(255, 215, 0, 0.5);
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.mellstroy-casino-modal.show .mellstroy-casino-modal-content {
    transform: scale(1);
}

.mellstroy-casino-modal-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255, 215, 0, 0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.mellstroy-casino-modal-title {
    color: #FFD700;
    font-size: 20px;
    font-weight: 700;
    margin: 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.mellstroy-casino-modal-close {
    background: none;
    border: none;
    color: #FFD700;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.mellstroy-casino-modal-close:hover {
    background: rgba(255, 215, 0, 0.2);
    transform: scale(1.1);
}

.mellstroy-casino-modal-body {
    padding: 20px;
    color: #ffffff;
    line-height: 1.6;
}

.mellstroy-casino-benefits-list {
    list-style: none;
    padding: 0;
    margin: 15px 0;
}

.mellstroy-casino-benefits-list li {
    padding: 8px 0;
    color: #ffffff;
    font-size: 14px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

.mellstroy-casino-modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.mellstroy-casino-modal-cancel {
    padding: 12px 24px;
    background: transparent;
    border: 1px solid rgba(255, 215, 0, 0.5);
    color: #FFD700;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mellstroy-casino-modal-cancel:hover {
    background: rgba(255, 215, 0, 0.1);
    border-color: #FFD700;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

/* ========== УЛУЧШЕНИЯ АНИМАЦИЙ ========== */
@keyframes mellstroy-glow-pulse {
    0%, 100% {
        box-shadow: 0 0 15px rgba(255, 215, 0, 0.4);
    }
    50% {
        box-shadow: 0 0 25px rgba(255, 215, 0, 0.7);
    }
}

@keyframes mellstroy-float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-5px);
    }
}

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

/* ========== СЕМАНТИЧЕСКИЕ УЛУЧШЕНИЯ СУЩЕСТВУЮЩИХ ЭЛЕМЕНТОВ ========== */

/* Улучшения для игровых карточек */
.game-card {
    transition: all 0.3s ease;
}

.game-card:hover {
    animation: mellstroy-glow-pulse 2s infinite;
}

/* Улучшения для промо карточек */
.promo-card {
    transition: all 0.3s ease;
}

.promo-card:hover {
    animation: mellstroy-float 3s ease-in-out infinite;
}

/* Улучшения для CTA кнопок */
.cta-button,
.cta-button-small {
    position: relative;
    overflow: hidden;
}

.cta-button::before,
.cta-button-small::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.cta-button:hover::before,
.cta-button-small:hover::before {
    left: 100%;
}

/* ========== СЕМАНТИЧЕСКОЕ ЛОГИРОВАНИЕ ========== */
.mellstroy-casino-tracked {
    cursor: pointer;
}

.mellstroy-casino-tracked::after {
    /* Визуальный индикатор для отслеживаемых элементов в dev режиме */
}

/* ========== АДАПТИВНЫЕ УЛУЧШЕНИЯ ========== */
@media (max-width: 768px) {
    .mellstroy-casino-modal-content {
        margin: 20px;
        max-width: calc(100% - 40px);
    }
    
    .mellstroy-casino-modal-actions {
        flex-direction: column;
    }
    
    .mellstroy-casino-modal-actions > * {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .mellstroy-casino-modal-header {
        padding: 15px;
    }
    
    .mellstroy-casino-modal-body {
        padding: 15px;
    }
    
    .mellstroy-casino-modal-title {
        font-size: 18px;
    }
}

/* ========== УТИЛИТЫ ========== */
.mellstroy-casino-hidden {
    display: none !important;
}

.mellstroy-casino-visible {
    display: block !important;
}

.mellstroy-casino-fade-in {
    animation: fadeInUp 0.5s ease forwards;
}

.mellstroy-casino-highlight {
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 8px;
}

/* ========== СЕМАНТИЧЕСКИЕ ИНДИКАТОРЫ ========== */
[data-mellstroy-casino="true"]::before {
    /* Можно добавить визуальные индикаторы для семантической разметки в dev режиме */
}

/* ========== ПЕЧАТЬ ========== */
@media print {
    .mellstroy-casino-modal {
        display: none !important;
    }
    
    [data-mellstroy-casino]::after {
        content: " [Mellstroy Casino]";
        font-size: 10px;
        color: #666;
    }
}

/* ========== ВЫСОКИЙ КОНТРАСТ ========== */
@media (prefers-contrast: high) {
    .mellstroy-casino-modal-content {
        border-width: 3px;
        border-color: #FFD700;
    }
    
    .mellstroy-casino-modal-title {
        text-shadow: none;
        font-weight: 900;
    }
}

/* ========== УМЕНЬШЕННАЯ АНИМАЦИЯ ========== */
@media (prefers-reduced-motion: reduce) {
    .mellstroy-casino-modal,
    .mellstroy-casino-modal-content,
    .game-card,
    .promo-card,
    .cta-button,
    .cta-button-small {
        transition: none !important;
        animation: none !important;
    }
}