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

body {
    min-height: 100vh;
    font-family: Arial, sans-serif;
    background: #121212;
    color: #ffffff;
    overflow-x: hidden;
    padding-top: 80px;
}

.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.star {
    position: absolute;
    background: rgb(46, 72, 216);
    border-radius: 50%;
    opacity: 0.8;
    animation: twinkle var(--duration) infinite alternate;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.2; }
    50% { opacity: 1; }
}

.container {
    position: relative;
    z-index: 1;
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    padding: 20px;
    justify-items: center;
}

@media (min-width: 768px) {
    .container {
        grid-template-columns: repeat(2, 1fr);
    }
}

.game-card {
    
    border-radius: 40px;
    padding: 15px;
    display: flex;
    animation: cardTwinkle 3s ease-in-out infinite;
    flex-direction: column;
    align-items: center;
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    max-width: 220px;
}

.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.3);
    border-color: rgba(0, 255, 255, 0.2);
}

.game-image {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    border-radius: 100px;
    margin-bottom: 15px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.game-card:hover .game-image {
    transform: scale(1.05);
}

.play-button {
    background: rgb(51, 121, 161);
    color: white;
    border: none;
    width: 100%;
    padding: 8px 0;
    cursor: pointer;
    font-size: 16px;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: bold;
    text-align: center;
    transition: all 0.3s ease;
}

.play-button:hover {
    background: #2e787d;
    box-shadow: 0 0 15px rgba(76, 147, 175, 0.4);
}

.top-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 40px;
    z-index: 1000;
    background: transparent;
}


.language-switcher, .device-info {
    padding: 8px 15px;
    height: 40px;
    animation: pulseGlow 3s ease-in-out infinite;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 30px;
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
}

.language-switcher:hover, .device-info:hover {
    background: rgba(255, 255, 255, 0.15);
}

.lang-flag {
    width: 28px;
    height: 28px;
    object-fit: cover;
    display: inline-block;
    margin-right: 8px;
    border-radius: 50%;
    vertical-align: middle;
}

.lang-text, .device-info-text {
    color: white;
    font-size: 16px;
    font-weight: bold;
    line-height: 40px;
    margin-left: 8px;
    vertical-align: middle;
}

.lang-options {
    position: absolute;
    top: calc(100% + 5px);
    right: 40px;
    background: rgba(30, 30, 30, 0.6);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    overflow: hidden;
    transform-origin: top;
    transform: scaleY(0);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    min-width: 120px;
    pointer-events: none;
    max-height: 300px;
    overflow-y: auto;
}

.lang-options.show {
    transform: scaleY(1);
    opacity: 1;
    pointer-events: all;
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 5px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.lang-option:hover {
    background: rgba(255, 255, 255, 0.2);
}

.hidden {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

.hidden .lang-options {
    transform: scaleY(0);
    opacity: 0;
    pointer-events: none;
}



.game-image {
    border-radius: 40px;
}


.play-button {
    background: linear-gradient(145deg, #2cd4be, #2d9b32);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3),
                inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-radius: 30px;
}

.play-button:hover {
    background: linear-gradient(145deg, rgb(47, 145, 170), rgb(209, 66, 9));
    box-shadow: 0 6px 12px rgb(34, 172, 149),
                inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

@keyframes floatStar {
    0% {
        transform: translate(0px, 0px);
    }
    50% {
        transform: translate(var(--dx), var(--dy));
    }
    100% {
        transform: translate(0px, 0px);
    }
}

.star {
    animation: twinkle var(--duration) infinite alternate,
               floatStar var(--duration) ease-in-out infinite;
    --dx: 0px;
    --dy: 0px;
}

.device-info {
    background: rgba(0, 255, 255, 0.05);
    border: 1px solid rgba(0, 255, 255, 0.3);
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
    border-radius: 30px;
    animation: pulseGlow 3s ease-in-out infinite;
}

@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
    }
    50% {
        box-shadow: 0 0 20px rgba(0, 255, 255, 0.6);
    }
}

.device-info-icon {
    font-size: 22px;
    filter: drop-shadow(0 0 2px cyan);
}

@keyframes cardTwinkle {
    0%, 100% {
        box-shadow: 0 0 10px rgba(0, 255, 255, 0.1);
    }
    50% {
        box-shadow: 0 0 20px rgba(0, 255, 255, 0.4);
    }
}

.bot-menu {
    position: relative;
    display: flex;
    align-items: center;
  }
  

  .bot-menu-glow {
    animation: cardTwinkle 3s ease-in-out infinite;
    border-radius: 999px;
    padding: 0px;
    background: transparent;
  }

.bot-trigger {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    width: auto;
    padding: 6px 14px;
    border-radius: 25px;
    background: #111;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 10px rgba(0,255,255,0.2);
    transition: all 0.3s ease;
}

.bot-trigger:hover {
    box-shadow: 0 0 20px rgba(0,255,255,0.4);
}

.bot-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    background: rgba(30, 30, 30, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 8px 0;
    min-width: 160px;
    display: none;
    flex-direction: column;
    z-index: 1001;
}

.bot-dropdown.show {
    display: flex;
}

.bot-item {
    padding: 10px 15px;
    color: white;
    cursor: pointer;
    transition: background 0.3s ease;
}

.bot-item:hover {
    background: rgba(255,255,255,0.1);
}

.bot-trigger img.lang-flag {
    display: block;
    object-fit: cover;
    height: 28px;
    width: 28px;
    margin: 0;
}
.bot-settings {
    display: none;
    flex-direction: column;
    padding: 5px 10px 10px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 6px;
}

.bot-setting-item label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: white;
    cursor: pointer;
}

.settings-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(30, 30, 30, 0.9);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 20px;
    z-index: 2000;
    display: none;
    box-shadow: 0 0 20px rgba(0,255,255,0.2);
    color: white;
  }
  
  .settings-box {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }
  
  .settings-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 8px;
  }
  
  .settings-button {
    padding: 10px;
    font-size: 14px;
    background: #222;
    color: white;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 8px;
    cursor: pointer;
    transition: 0.2s;
  }
  
  .settings-button:hover {
    background: rgba(0,255,255,0.1);
  }
  
  .settings-close {
    margin-top: 10px;
    padding: 8px;
    background: crimson;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
  }

  .profile-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(30, 30, 30, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 20px;
    z-index: 2000;
    display: none;
    box-shadow: 0 0 20px rgba(0,255,255,0.2);
    color: white;
    min-width: 260px;
  }
  
  .profile-box {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }
  
  .profile-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 8px;
  }
  
  .profile-close {
    margin-top: 10px;
    padding: 8px;
    background: crimson;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
  }
  
  #nickname-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }
  
  #nickname-input {
    padding: 6px;
    font-size: 14px;
    border-radius: 6px;
    border: none;
  }
  
  #nickname-section button {
    padding: 8px;
    background: seagreen;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
  }

  @keyframes profileFadeIn {
    from {
      opacity: 0;
      transform: translate(-50%, -60%) scale(0.95);
    }
    to {
      opacity: 1;
      transform: translate(-50%, -50%) scale(1);
    }
  }
  
  .animated-profile {
    animation: profileFadeIn 0.4s ease forwards;
  }

  @keyframes settingsFadeIn {
    from {
      opacity: 0;
      transform: translate(-50%, -60%) scale(0.95);
    }
    to {
      opacity: 1;
      transform: translate(-50%, -50%) scale(1);
    }
  }
  
  .animated-settings {
    animation: settingsFadeIn 0.4s ease forwards;
  }
  
  .particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: -1;
  }
  
  .particle {
    position: absolute;
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation: float 10s linear infinite;
  }
  
  @keyframes float {
    0% {
      transform: translateY(0) scale(1);
      opacity: 0.5;
    }
    50% {
      opacity: 1;
      transform: translateY(-100px) scale(1.3);
    }
    100% {
      transform: translateY(0) scale(1);
      opacity: 0.5;
    }
  }
  