* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.5);
}

/* Counter Upgrade Panel için animasyonlar */
@keyframes slideFromTopBounce {
    0% { transform: translateY(-150%) scale(0.9); opacity: 0; }
    70% { transform: translateY(5%) scale(1.05); opacity: 1; }
    85% { transform: translateY(-2%) scale(0.98); opacity: 1; }
    100% { transform: translateY(0) scale(1); opacity: 1; }
}

@keyframes slideFromBottomBounce {
    0% { transform: translateY(150%) scale(0.9); opacity: 0; }
    70% { transform: translateY(-5%) scale(1.05); opacity: 1; }
    85% { transform: translateY(2%) scale(0.98); opacity: 1; }
    100% { transform: translateY(0) scale(1); opacity: 1; }
}

@keyframes slideFromLeftBounce {
    0% { transform: translateX(-150%) scale(0.9); opacity: 0; }
    70% { transform: translateX(5%) scale(1.05); opacity: 1; }
    85% { transform: translateX(-2%) scale(0.98); opacity: 1; }
    100% { transform: translateX(0) scale(1); opacity: 1; }
}

@keyframes slideFromRightBounce {
    0% { transform: translateX(150%) scale(0.9); opacity: 0; }
    70% { transform: translateX(-5%) scale(1.05); opacity: 1; }
    85% { transform: translateX(2%) scale(0.98); opacity: 1; }
    100% { transform: translateX(0) scale(1); opacity: 1; }
}

@keyframes zoomInBounce {
    0% { transform: scale(0); opacity: 0; }
    70% { transform: scale(1.05); opacity: 1; }
    85% { transform: scale(0.98); opacity: 1; }
    100% { transform: scale(1); opacity: 1; }
}

@keyframes pulseButton {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Panel ana container animasyonu */
.cup-panel {
    animation: zoomInBounce 0.8s ease-out forwards;
}

/* Header animasyonu */
.cup-header {
    animation: slideFromTopBounce 0.8s ease-out forwards;
}

/* Başlık animasyonu */
.cup-title {
    animation: slideFromLeftBounce 0.9s ease-out forwards;
}

/* Level bar animasyonu */
.cup-level-bar {
    animation: slideFromRightBounce 0.9s ease-out forwards;
}

/* Counter kartları animasyonu */
.cup-counter-card {
    opacity: 0;
    animation: zoomInBounce 1s ease-out forwards;
}

/* Her kart için farklı gecikme */
.cup-counter-card:nth-child(1) {
    animation-delay: 0.2s;
}

.cup-counter-card:nth-child(2) {
    animation-delay: 0.3s;
}

.cup-counter-card:nth-child(3) {
    animation-delay: 0.4s;
}

/* Kart içindeki resim animasyonu */
.cup-counter-img {
    animation: zoomInBounce 1.1s ease-out forwards;
    animation-delay: 0.5s;
    opacity: 0;
}

/* Yıldız ve ödül animasyonu */
.cup-star-reward {
    animation: slideFromTopBounce 1.2s ease-out forwards;
    animation-delay: 0.6s;
    opacity: 0;
}

/* Upgrade bilgisi animasyonu */
.cup-upgrade-info {
    animation: slideFromLeftBounce 1.2s ease-out forwards;
    animation-delay: 0.7s;
    opacity: 0;
}

/* Seçim butonu animasyonu */
.cup-select-button {
    animation: slideFromBottomBounce 1.2s ease-out forwards, pulseButton 1.5s infinite ease-in-out 1.2s;
    animation-delay: 0.8s;
    opacity: 0;
}

.cup-select-button:hover {
    transform: scale(1.1);
}

/* Kapat butonu animasyonu */
.cup-close-button {
    animation: zoomInBounce 1s ease-out forwards;
    animation-delay: 0.9s;
    opacity: 0;
}

.cup-close-button:hover {
    transform: scale(1.1);
}

/* Para göstergesi animasyonu */
.cup-money-display {
    animation: slideFromRightBounce 1s ease-out forwards;
    animation-delay: 0.5s;
    opacity: 0;
}

/* Animasyon tamamlandığında elementleri göster */
.cup-panel, .cup-header, .cup-title, .cup-level-bar, 
.cup-counter-card, .cup-counter-img, .cup-star-reward, 
.cup-upgrade-info, .cup-select-button, .cup-close-button,
.cup-money-display {
    animation-fill-mode: forwards;
    
}

/* Counter Upgrade Panel Styles */
.cup-panel {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    background-color: rgba(0, 0, 0, 0.7); /* Background opacity'yi artır */
    backdrop-filter: blur(3px);
    z-index: 2000;
    font-family: 'english_font', sans-serif;
    padding: 80px 20px 20px; /* Padding'i optimize et */
    box-sizing: border-box; /* Box sizing ekle */
    overflow: hidden; /* Taşan içeriği gizle */
}

/* Desktop için responsive ayarlar */
@media (hover: hover) and (pointer: fine) {
    .cup-panel {
        padding: 64px 16px 16px; /* %20 küçültme: 80px->64px, 20px->16px */
        justify-content: center;
        align-items: center;
    }

    .cup-panel > * {
        width: 80%;
        max-width: 1000px;
        min-width: 600px;
        box-sizing: border-box;
    }
}

/* Header styles */
.cup-header {
    background-color: #ff6347; /* Coral color for header */
    padding: 12px 0; /* Padding'i azalt */
    text-align: center;
    margin-top: 0; /* Margin'i kaldır */
    flex-shrink: 0; /* Header'ın küçülmesini engelle */
}

.cup-title {
    color: white;
    font-size: 28px; /* Font boyutunu küçült */
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.cup-level-bar {
    background-color: rgba(0, 0, 0, 0.3);
    padding: 8px 0; /* Padding'i azalt */
    text-align: center;
    flex-shrink: 0; /* Level bar'ın küçülmesini engelle */
}

.cup-level-text {
    color: white;
    font-size: 20px; /* Font boyutunu küçült */
    font-weight: bold;
}

/* Content area */
.cup-content {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center; /* Center'a al */
    padding: 15px 10px; /* Padding'i azalt */
    gap: 8px; /* Kartlar arası boşluk ekle */
    margin: 0; /* Margin'i kaldır */
    min-height: 0; /* Min height ekle */
    overflow: hidden; /* Taşan içeriği gizle */
}

/* Counter card styles - common properties */
.cup-counter-card {
    width: 160px; /* Kart genişliğini azalt */
    height: 280px; /* Kart yüksekliğini azalt */
    border-radius: 7px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    position: relative;
    background-color: transparent;
    margin: 0 4px; /* Kartlar arası boşluğu azalt */
    min-width: 160px; /* Minimum genişliği güncelle */
    flex-shrink: 0; /* Kartların küçülmesini engelle */
}
/* Standard card styles */
.cup-standard-card-img {
    width: 100%;
    height: 100%;
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    object-fit: cover; /* Resmi karta sığdır */

    user-select: none;
    pointer-events: none;
}

/* Premium card styles */
.cup-premium-card-img {
    width: 100%;
    height: 100%;
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    object-fit: cover; /* Resmi karta sığdır */

    user-select: none;
    pointer-events: none;
}

.cup-card-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px; /* Padding'i azalt */
    height: 100%;
}

.cup-counter-img {
    width: 75%; /* Genişliği azalt */
    height: auto;
    object-fit: contain;
    display: block;
    margin: 15px auto -5px; /* Margin'i azalt */
    position: relative;
    user-select: none;
    pointer-events: none;
}

/* Button containers */
.cup-select-btn-container, .cup-free-btn-container {
    position: relative;
    width: 80%;
    height: 40px; /* Yüksekliği azalt */
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    margin-top: 8px; /* Margin'i azalt */
}

.cup-button-img {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 1;
}

.cup-select-btn-container .cup-money-icon {
    width: 24px; /* İkon boyutunu azalt */
    height: 24px;
    margin-right: 0;
    position: relative;
    z-index: 2;
}

.cup-select-btn-container span {
    color: #005F0C;
    font-size: 16px; /* Font boyutunu azalt */
    font-weight: bold;
    position: relative;
    z-index: 2;
}

.cup-button-text {
    position: relative;
    z-index: 2;
    font-size: 16px; /* Font boyutunu azalt */
    font-weight: bold;
}

.cup-select-btn-container .cup-button-text {
    color: #005F0C; /* Green button text color */
}

.cup-free-btn-container .cup-button-text {
    color: #9A3800; /* Yellow button text color */
    margin-left: 3px; /* Video icon için yer açar */
}

.cup-video-icon {
    width: 17px; /* İkon boyutunu büyüttüm */
    height: 17px;
    position: relative;
    z-index: 2;
    margin-right: 8px;

    user-select: none;
    pointer-events: none;
}

/* Eski buton stillerini kaldır */
.cup-select-btn, .cup-free-btn {
    display: none;
}

/* Premium card için özel stiller */
.cup-premium-card .cup-expert-text,
.cup-premium-card .cup-speed-value {
    color: #2529FF; /* Gold color */
}

.cup-premium-card {
    color: #FFF9F1; /* Gold color */
    font-weight: bold;
    font-size: 18px;
}

.cup-star-reward {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    align-items: center;
    background-color: transparent;
}

.cup-star-value {
    color: #FFF9F1; /* Gold color */
    font-weight: bold;
    font-size: 14px; /* Font boyutunu azalt */
    margin-left: 20px; /* Margin'i azalt */
    margin-top: -4px;
}

.cup-card-info {
    color: #662709;
    padding: 8px 12px;
    text-align: center;
    margin-top: 15px; /* Yazıları aşağıya almak için margin ekle */
    margin-bottom: 8px; /* Bottom margin'i artır */
}

.cup-hire-text {
    font-size: 13px; /* Font boyutunu azalt */
    margin-bottom: 3px; /* Margin'i azalt */
}

.cup-expert-text {
    color: #32cd32; /* Lime green */
    font-weight: bold;
    font-size: 13px; /* Font boyutunu azalt */
}

.cup-speed-text {
    font-size: 13px; /* Font boyutunu azalt */
    font-weight: bold;
}

.cup-speed-value {
    color: #32cd32; /* Lime green */
    font-weight: bold;
    font-size: 13px; /* Font boyutunu azalt */
}

/* Card button container - !important ekleyerek değişikliklerin uygulanmasını sağlayalım */
.cup-card-button {
    width: 100% !important;
    display: flex !important;
    justify-content: center !important;
    margin-top: auto !important;
    margin-bottom: 15px !important; /* Butonu daha aşağıya almak için margin'i azalt */
}

.cup-card-button:hover {
    transform: scale(1.1);
}

/* Premium button container */
.premium-button-container {
    position: absolute;
    bottom: 15px;
    left: 0;
    width: 100%;
    text-align: center;
}

/* Responsive tasarım için medya sorguları */
@media (max-width: 768px) and (pointer: coarse) {
    .cup-panel {
        width: 100vw;
        height: 100vh;
        overflow: hidden;
        padding: 60px 15px 15px; /* Padding'i azalt */
    }

    .cup-header {
        padding: 10px 0; /* Header padding'i azalt */
    }

    .cup-title {
        font-size: 24px; /* Font boyutunu azalt */
    }

    .cup-level-text {
        font-size: 18px; /* Font boyutunu azalt */
    }

    .cup-content {
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        padding: 10px 5px; /* Padding'i azalt */
        margin: 0;
        gap: 6px; /* Gap'i azalt */
    }

    .cup-counter-card {
        flex: 0 0 auto;
        width: 140px; /* Genişliği azalt */
        height: 240px; /* Yüksekliği azalt */
        margin: 0 3px; /* Margin'i azalt */
        min-width: 140px;
    }
    
    /* Counter image pozisyonunu koru */
    .cup-counter-img {
        width: 70%;
        margin: 15px auto -10px;
        position: relative;
        top: 20px;
    }
    
    /* Card content padding'ini koru */
    .cup-card-content {
        position: relative;
        padding-top: 20px;
    }
    
    /* Kart bilgilerini aşağı al */
    .cup-card-info {
        padding: 5px 15px;
        margin-top: 35px; /* Margin'i artırarak yazıyı aşağı al (30px'ten 35px'e) */
        margin-bottom: 8px;
        min-height: 60px;
    }
    
    /* Butonları aşağı al */
    .cup-counter-card .cup-card-button {
        margin-bottom: 30px !important; /* Margin'i azaltarak butonu aşağı al (50px'ten 30px'e) */
    }
    
    .cup-select-btn-container, 
    .cup-free-btn-container {
        height: 40px;
        margin-top: 0;
    }
    
    .cup-button-text {
        font-size: 16px;
    }
    
    .cup-video-icon {
        width: 14px;
        height: 14px;
    }
    
    .cup-star-value {
        margin-left: 13px;
        margin-top: -5px;
        font-size: 14px;
    }

    .cup-hire-text {
        font-size: 11px; /* 16px'ten 14px'e düşür */
        margin-bottom: 3px;
    }
    
    .cup-expert-text {
        font-size: 11px; /* Font boyutunu düşür */
        font-weight: bold;
    }
    
    .cup-speed-text {
        font-size: 11px; /* 16px'ten 14px'e düşür */
        font-weight: bold;
    }
    
    .cup-speed-value {
        font-size: 11px; /* Font boyutunu düşür */
        font-weight: bold;
    }
}

/* Daha küçük ekranlar için */
@media (max-width: 480px) and (pointer: coarse) {
    .cup-panel {
        padding: 50px 10px 10px; /* Padding'i daha da azalt */
    }

    .cup-title {
        font-size: 20px; /* Font boyutunu daha da azalt */
    }

    .cup-level-text {
        font-size: 16px; /* Font boyutunu daha da azalt */
    }

    .cup-content {
        gap: 4px; /* Gap'i daha da azalt */
        padding: 8px 2px; /* Padding'i azalt */
    }

    .cup-counter-card {
        width: 120px; /* Genişliği daha da azalt */
        height: 210px; /* Yüksekliği daha da azalt */
        min-width: 120px;
        margin: 0 2px; /* Margin'i azalt */
    }

    /* Counter image pozisyonunu koru */
    .cup-counter-img {
        width: 65%;
        margin: 8px auto -8px; /* Margin'i azalt */
        position: relative;
        top: 12px; /* Top'u azalt */
    }

    /* Card content padding'ini koru */
    .cup-card-content {
        position: relative;
        padding: 6px; /* Padding'i azalt */
    }

    /* Kart bilgilerini optimize et */
    .cup-card-info {
        padding: 4px 8px; /* Padding'i azalt */
        margin-top: 20px; /* Margin'i azalt */
        margin-bottom: 6px;
        min-height: 40px; /* Min height'i azalt */
    }

    /* Butonları optimize et */
    .cup-counter-card .cup-card-button {
        margin-bottom: 8px !important; /* Margin'i azalt */
    }

    .cup-select-btn-container,
    .cup-free-btn-container {
        height: 32px; /* Yüksekliği azalt */
        margin-top: 4px; /* Margin'i azalt */
    }

    .cup-button-text {
        font-size: 12px; /* Font boyutunu azalt */
    }

    .cup-video-icon {
        width: 12px; /* İkon boyutunu azalt */
        height: 12px;
    }
}

/* Disabled button styles */
.cup-select-btn-container.disabled {
    cursor: not-allowed;
}

.cup-select-btn-container.disabled .money-icon,
.cup-select-btn-container.disabled span {
    opacity: 0.7;
}
