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

body {
    font-family: 'Arial', sans-serif;
    background-image: url(assets/img/hero61-bg.png);
    color: #ffffff;
    overflow: hidden;
    height: 100vh;
	background-size: cover;
	background-position: center;
	
}
@media (max-width: 768px) {
  body {
    background-image: 
      
      url('assets/img/8.png');
  }
  
  @supports (background-image: image-set("dummy" 1x)) {
    body {
      background-image: 
        
        image-set(
          url('assets/img/8.png') 1x,
          url('assets/img/8.png') 2x
        );
    }
  }
}

/* Планшеты (769-1024px) */
@media (min-width: 769px) and (max-width: 1024px) {
  body {
    background-image: url('assets/img/8.png');
  }
}

/* Десктоп (1025px+) */
@media (min-width: 1025px) {
  body {
    background-image: url('assets/img/hero61-bg.png');
  }
}
#gameContainer {
    position: relative;
    width: 100vw;
    height: 100vh;
}















/* Панель заданий */
.tasks-panel {
    position: fixed;
    top: 120px;
    right: 20px;
    width: 350px;
	height: 750px;
    
    background: linear-gradient(160deg, #0a1428 30%, #1a365d 100%);
    border: 2px solid #4299e1;
    border-radius: 15px 0 0 15px;
    transition: right 0.3s ease;
    z-index: 150;
    display: flex;
    flex-direction: column;
    box-shadow: -5px 0 20px rgba(66, 153, 225, 0.3);
}

.tasks-panel.open {
    right: 0;
}

.tasks-header {
    background: linear-gradient(90deg, #2c5282, #4299e1);
    padding: 15px;
    border-radius: 13px 0 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: white;
}

.tasks-header h3 {
    margin: 0;
    font-size: 16px;
}

.tasks-toggle-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.tasks-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.tasks-panel.open .tasks-toggle-btn i {
    transform: rotate(180deg);
}

.tasks-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.task-item {
    background: rgba(44, 82, 130, 0.6);
    border: 1px solid rgba(66, 153, 225, 0.3);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.task-item:hover {
    border-color: #4299e1;
    transform: translateX(-5px);
}

.task-item.completed {
    border-color: #48bb78;
    background: rgba(72, 187, 120, 0.2);
}

.task-item.claimed {
    opacity: 0.6;
    filter: grayscale(50%);
}

.task-title {
    color: #63b3ed;
    font-weight: bold;
    font-size: 14px;
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.task-description {
    color: #cbd5e0;
    font-size: 12px;
    margin-bottom: 10px;
    line-height: 1.4;
}

.task-progress {
    margin-bottom: 10px;
}

.progress-text {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #a0aec0;
    margin-bottom: 5px;
}

.progress-bar-container {
    background: rgba(10, 20, 40, 0.8);
    height: 6px;
    border-radius: 3px;
    overflow: hidden;
}

.progress-bar-fill {
    background: linear-gradient(90deg, #4299e1, #63b3ed);
    height: 100%;
    transition: width 0.5s ease;
    border-radius: 3px;
}

.task-reward {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
}

.reward-info {
    color: #48bb78;
    display: flex;
    gap: 10px;
}

.claim-btn {
    background: linear-gradient(135deg, #48bb78, #38a169);
    border: none;
    color: white;
    padding: 5px 12px;
    border-radius: 5px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.claim-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 10px rgba(72, 187, 120, 0.4);
}

.claim-btn:disabled {
    background: #2d3748;
    cursor: not-allowed;
    transform: none;
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .tasks-panel {
        width: 300px;
        right: -280px;
    }
    
    .tasks-content {
        padding: 15px;
    }
    
    .task-item {
        padding: 12px;
    }
}
@keyframes taskComplete {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); border-color: #48bb78; }
    100% { transform: scale(1); }
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes slideOut {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(100%); opacity: 0; }
}

.tasks-panel {
    animation: slideIn 0.5s ease-out;
}














.rank-image {
    width: 80px;
    height: 80px;

    border-radius: 40%;
    
    display: block;
    margin-left: auto;
    margin-right: auto;
	
    
    
    object-fit: cover;
   
}

.rank-info {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.rank-name {
    color: #63b3ed;
    font-weight: bold;
    font-size: 14px;
    margin-bottom: 2px;
}

.rank-tokens {
    color: #48bb78;
    font-size: 12px;
    font-family: monospace;
}



/* Мобильная адаптация */
@media (max-width: 768px) {
    .rank-display {
        min-width: 150px;
        padding: 8px;
    }
    
    .rank-image {
        width: 32px;
        height: 32px;
        margin-right: 8px;
    }
    
    .rank-name {
        font-size: 12px;
    }
    
    .rank-tokens {
        font-size: 10px;
    }
}





#charactersModal {
    backdrop-filter: blur(10px);
    background: linear-gradient(45deg, rgba(10,20,40,0.95), rgba(26,54,93,0.95));
}

#charactersModal .modal-content {
    background: linear-gradient(160deg, #0a1428 30%, #1a365d 100%);
    border: 2px solid #4299e1;
    border-radius: 15px;
    max-width: 900px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

/* Сетка персонажей */
.characters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    padding: 20px;
    max-height: 300px;
    overflow-y: auto;
}

.character-card {
    background: linear-gradient(145deg, rgba(44,82,130,0.8), rgba(26,54,93,0.9));
    border: 2px solid rgba(66,153,225,0.3);
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.character-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(66,153,225,0.3);
    border-color: #4299e1;
}

.character-card.selected {
    border-color: #48bb78;
    background: linear-gradient(145deg, rgba(72,187,120,0.2), rgba(26,54,93,0.9));
}

.character-card.locked {
    opacity: 0.5;
    cursor: not-allowed;
    position: relative;
}

.character-card.locked::after {
    content: "🔒";
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 20px;
}

.character-avatar {
    width: 90px;
    height: 90px;
    background: radial-gradient(circle, rgba(66,153,225,0.3), transparent);
    border-radius: 50%;
    margin: 0 auto 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}


.character-name {
    color: #63b3ed;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 5px;
}

.character-cost {
    color: #48bb78;
    font-size: 12px;
    font-family: monospace;
}

/* Превью персонажа */
.character-preview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding: 20px;
    border-top: 1px solid rgba(66,153,225,0.3);
}

.preview-model {
    background: rgba(10,20,40,0.8);
    border-radius: 10px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #2c5282;
}

.character-stats h4 {
    color: #4299e1;
    margin-bottom: 10px;
}

.character-stats p {
    color: #cbd5e0;
    font-size: 14px;
    margin-bottom: 15px;
}

.stats-list {
    display: grid;
    gap: 8px;
    margin-bottom: 20px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 12px;
    background: rgba(44,82,130,0.5);
    border-radius: 6px;
}

.stat-item span:first-child {
    color: #a0aec0;
}

.stat-item span:last-child {
    color: #63b3ed;
    font-weight: bold;
}

/* Адаптация для мобильных */
@media (max-width: 768px) {
    .character-preview {
        grid-template-columns: 1fr;
    }
    
    .characters-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}









/* Кнопка вызова чата */
.chat-toggle-btn {
    position: fixed;
    bottom: 120px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #2c5282, #1a365d);
    border: 2px solid #4299e1;
    border-radius: 50%;
    color: white;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(66, 153, 225, 0.3);
}

.chat-toggle-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(66, 153, 225, 0.5);
}

.chat-notification {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #e53e3e;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* Модальное окно чата */
.chat-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-container {
    background: linear-gradient(160deg, #0a1428 30%, #1a365d 100%);
    border: 2px solid #4299e1;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    height: 600px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 0 40px rgba(66, 153, 225, 0.3);
}

.chat-header {
    background: linear-gradient(90deg, #2c5282, #4299e1);
    padding: 15px 20px;
    border-radius: 13px 13px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: white;
}

.chat-close {
    background: none;
    border: none;
    color: white;
    font-size: 18px;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.chat-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Область сообщений */
.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.message {
    max-width: 80%;
    padding: 12px 16px;
    border-radius: 18px;
    word-wrap: break-word;
    position: relative;
    animation: messageSlide 0.3s ease;
}

.message.own {
    background: linear-gradient(135deg, #4299e1, #63b3ed);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.message.other {
    background: rgba(44, 82, 130, 0.8);
    color: #e2e8f0;
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.message-info {
    font-size: 10px;
    opacity: 0.7;
    margin-top: 4px;
}

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

/* Поле ввода */
.chat-input-container {
    padding: 15px;
    border-top: 1px solid rgba(66, 153, 225, 0.3);
    display: flex;
    gap: 10px;
    align-items: center;
}

#chatInput {
    flex: 1;
    background: rgba(44, 82, 130, 0.5);
    border: 2px solid #2c5282;
    border-radius: 25px;
    padding: 12px 16px;
    color: white;
    font-size: 14px;
    outline: none;
    transition: border-color 0.3s ease;
}

#chatInput:focus {
    border-color: #4299e1;
    box-shadow: 0 0 10px rgba(66, 153, 225, 0.3);
}

#chatInput::placeholder {
    color: #a0aec0;
}

.send-btn, .emoji-btn {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #4299e1, #63b3ed);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.send-btn:hover, .emoji-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(66, 153, 225, 0.4);
}

/* Панель эмодзи */
.emoji-picker-container {
    position: relative;
}

.emoji-picker {
    position: absolute;
    bottom: 50px;
    left: 0;
    background: linear-gradient(160deg, #0a1428 30%, #1a365d 100%);
    border: 2px solid #4299e1;
    border-radius: 10px;
    padding: 15px;
    width: 280px;
    max-height: 200px;
    overflow-y: auto;
    box-shadow: 0 0 20px rgba(66, 153, 225, 0.3);
}

.emoji-categories {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.emoji-category {
    background: rgba(44, 82, 130, 0.6);
    border: 1px solid #4299e1;
    border-radius: 6px;
    padding: 8px 12px;
    color: white;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s ease;
}

.emoji-category:hover,
.emoji-category.active {
    background: #4299e1;
    transform: translateY(-2px);
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
}

.emoji-item {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.3s ease;
    font-size: 18px;
}

.emoji-item:hover {
    background: rgba(66, 153, 225, 0.3);
    transform: scale(1.1);
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .chat-container {
        width: 95%;
        height: 80vh;
    }
    
    .emoji-picker {
        width: 250px;
        left: -210px;
    }
    
    .emoji-grid {
        grid-template-columns: repeat(6, 1fr);
    }
}

.hidden {
    display: none !important;
}











#ui {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.modal1 {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 1000;
}

.modal-content1 {
    background: #1a365d;
    margin: 5% auto;
    padding: 20px;
    border: 2px solid #4299e1;
    border-radius: 10px;
    width: 90%;
    max-width: 600px;
    position: relative;
    color: white;
}















#playerStatsModal .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

#playerStatsModal .stat-item {
    background: rgba(26, 54, 93, 0.9);
    padding: 20px;
    border-radius: 12px;
    border: 2px solid #2c5282;
}

#playerStatsModal .stat-item i {
    font-size: 28px;
    margin-right: 15px;
}

#playerStatsModal h3 {
    color: #4299e1;
    text-align: center;
    margin-bottom: 25px;
    font-size: 24px;
}







#topPlayersModal .stats-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
}

.top-player-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: rgba(26, 54, 93, 0.9);
    border-radius: 8px;
    border: 2px solid #2c5282;
}

.player-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.player-rank {
    color: #4299e1;
    font-weight: bold;
    min-width: 30px;
}

.telegram-icon {
    color: #4299e1;
    font-size: 1.2em;
}

.player-tokens {
    color: #48bb78;
    font-family: monospace;
}





/* Модальное окно настроек */
#settingsModal {
    backdrop-filter: blur(10px);
    background: linear-gradient(45deg, rgba(10,20,40,0.95), rgba(26,54,93,0.95));
}

#settingsModal .modal-content {
    background: linear-gradient(160deg, #0a1428 30%, #1a365d 100%);
    border: 2px solid #4299e1;
    box-shadow: 0 0 40px rgba(66,153,225,0.3);
    border-radius: 15px;
    max-width: 600px;
    width: 90%;
}

/* Настройки контента */
.settings-content {
    padding: 20px;
}

.setting-item {
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(44, 82, 130, 0.3);
    border-radius: 10px;
    border: 1px solid rgba(66, 153, 225, 0.3);
}

.setting-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    color: #63b3ed;
    font-weight: 500;
}

/* Toggle Switch стили */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #2c5282;
    transition: 0.4s;
    border-radius: 34px;
    border: 2px solid #4299e1;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 2px;
    bottom: 2px;
    background-color: #4299e1;
    transition: 0.4s;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(66, 153, 225, 0.5);
}

input:checked + .slider {
    background-color: #48bb78;
    border-color: #48bb78;
}

input:checked + .slider:before {
    transform: translateX(26px);
    background-color: #fff;
    box-shadow: 0 0 15px rgba(72, 187, 120, 0.7);
}

/* Анимация свечения */
.slider:hover {
    box-shadow: 0 0 20px rgba(66, 153, 225, 0.4);
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .setting-label {
        font-size: 14px;
    }
    
    .toggle-switch {
        width: 50px;
        height: 28px;
    }
    
    .slider:before {
        height: 22px;
        width: 22px;
    }
    
    input:checked + .slider:before {
        transform: translateX(20px);
    }
}












.table-container1 {
    overflow-x: auto;
}

.stats-table1 {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.stats-table1 th, .stats-table1 td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #2c5282;
}

@media (max-width: 768px) {
    .stats-table1 th, .stats-table1 td {
        padding: 8px;
        font-size: 14px;
    }
    
    .modal-content1 {
        width: 95%;
        margin: 10% auto;
    }
}
.music-btn {
    position: fixed;
    bottom: 10px;
    right: 20px;
    width: 10px;
    height: 1px;
    background: rgba(44, 82, 130, 0.9);
    border: 2px solid #4299e1;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
}

.music-btn:hover {
    transform: scale(1.1);
}

.fa-music {
    color: #fff;
    font-size: 2.2rem;
}


#ui > div {
    background: linear-gradient(
        45deg,
        rgba(10, 20, 40, 0.5),
        rgba(44, 82, 130, 0.6),
        rgba(99, 179, 237, 0.5),
        rgba(44, 82, 130, 0.6),
        rgba(10, 20, 40, 0.5)
    );
    background-size: 300% 300%;
    padding: 10px 15px;
    border-radius: 28px;
    border: 2px solid #2c5282;
    font-size: 16px;
    font-weight: bold;
    animation: gradient-shift 3s ease-in-out infinite;
}

@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}






































#levelContainer {
    background: rgba(10, 20, 40, 0.9);
    padding: 15px;
    border-radius: 10px;
    border: 2px solid #2c5282;
    margin: 10px 0;
}

.progress-bar {
    height: 8px;
    background: #1a365d;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 10px;
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, #4299e1, #63b3ed);
    transition: width 0.3s ease;
}



























/* Модальное окно системы рангов */
#ranksModal {
    backdrop-filter: blur(10px);
    background: linear-gradient(45deg, rgba(10,20,40,0.95), rgba(26,54,93,0.95));
	overflow: auto;
  scrollbar-width: thin;
	width: 700px;
    height: 350px;
	position: center;

}

#ranksModal .modal-content {
    background: linear-gradient(160deg, #0a1428 30%, #1a365d 100%);
    border: 2px solid #4299e1;
    box-shadow: 0 0 40px rgba(66,153,225,0.3);
    border-radius: 15px;
    overflow: hidden;
	
}

#ranksModal h3 {
    background: linear-gradient(90deg, #4299e1, #63b3ed);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: 2em;
    text-align: center;
    padding: 20px;
    margin: 0;
    position: relative;
	
}

#ranksModal h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #4299e1, transparent);
}

/* Элементы рангов */
.rank-item {
    background: linear-gradient(145deg, rgba(44,82,130,0.8), rgba(26,54,93,0.9));
    border: 1px solid rgba(66,153,225,0.3);
    border-radius: 10px;
    margin: 15px;
    padding: 20px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.rank-item::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(66,153,225,0.1), transparent);
    transform: rotate(45deg);
    transition: 0.5s;
}

.rank-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(66,153,225,0.2);
}

.rank-item:hover::before {
    animation: rankGlow 1.5s infinite;
}



/* Текущий ранг */
.rank-item.current {
    border: 2px solid #48bb78;
    background: linear-gradient(145deg, rgba(72,187,120,0.15), rgba(26,54,93,0.9));
    animation: currentRankGlow 2s infinite;
}

@keyframes currentRankGlow {
    0%, 100% { box-shadow: 0 0 10px rgba(72,187,120,0.3); }
    50% { box-shadow: 0 0 20px rgba(72,187,120,0.6); }
}

/* Прогресс-бар */
.rank-progress {
    background: rgba(10,20,40,0.8);
    height: 8px;
    border-radius: 4px;
    margin-top: 15px;
    overflow: hidden;
}

.rank-progress-bar {
    background: linear-gradient(90deg, #4299e1, #63b3ed);
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.rank-progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: progressShine 2s infinite;
}

@keyframes progressShine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Информация о ранге */
.rank-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.rank-name {
    font-size: 1.1em;
    color: #63b3ed;
    font-weight: 600;
}

.rank-required {
    font-family: 'Courier New', monospace;
    color: #48bb78;
    font-size: 0.7em;
}

/* Адаптация для мобильных */
@media (max-width: 768px) {
    #ranksModal .modal-content {
        width: 95%;
        margin: 10px auto;
    }
    
    .rank-item {
        margin: 10px;
        padding: 15px;
    }
    
    .rank-name {
        font-size: 1em;
    }
    
    .rank-required {
        font-size: 0.9em;
    }
}














#gameMenu {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 200;
	
    
    /* Стеклянный эффект фона */
    background: rgba(10, 20, 40, 0.15);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    
    border: 2px solid transparent;
    border-radius: 20px;
    padding: 40px;
    min-width: 150px;
    
    /* Анимированная рамка */
    background-image: 
        linear-gradient(rgba(10, 20, 40, 0.8), rgba(10, 20, 40, 0.8)),
        conic-gradient(from var(--menu-angle),
            transparent 0deg,
            rgba(66, 153, 225, 0.8) 45deg,
            rgba(129, 230, 217, 0.8) 90deg,
            rgba(144, 205, 244, 0.8) 135deg,
            rgba(66, 153, 225, 0.8) 180deg,
            transparent 225deg,
            rgba(66, 153, 225, 0.8) 270deg,
            rgba(129, 230, 217, 0.8) 315deg,
            transparent 360deg
        );
    background-origin: padding-box, border-box;
    background-clip: padding-box, border-box;
    
    /* Внешнее свечение */
    box-shadow: 
        0 0 30px rgba(66, 153, 225, 0.3),
        0 0 60px rgba(66, 153, 225, 0.2),
        0 20px 40px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    
    animation: menuBorderRotate 8s linear infinite,
               menuFloat 4s ease-in-out infinite;
}

@property --menu-angle {
    syntax: "<angle>";
    initial-value: 0deg;
    inherits: false;
}

@keyframes menuBorderRotate {
    from {
        --menu-angle: 0deg;
    }
    to {
        --menu-angle: 360deg;
    }
}

@keyframes menuFloat {
    0%, 100% {
        transform: translate(-50%, -50%) translateY(0px);
    }
    50% {
        transform: translate(-50%, -50%) translateY(-5px);
    }
}
#gameMenu::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    background: conic-gradient(from var(--outer-glow-angle),
        transparent 0deg,
        rgba(66, 153, 225, 0.4) 30deg,
        transparent 60deg,
        rgba(129, 230, 217, 0.4) 120deg,
        transparent 150deg,
        rgba(144, 205, 244, 0.4) 210deg,
        transparent 240deg,
        rgba(66, 153, 225, 0.4) 300deg,
        transparent 360deg
    );
    border-radius: 24px;
    filter: blur(8px);
    opacity: 0.6;
    z-index: -1;
    animation: outerGlowRotate 12s linear infinite reverse;
}

@property --outer-glow-angle {
    syntax: "<angle>";
    initial-value: 0deg;
    inherits: false;
}

@keyframes outerGlowRotate {
    from {
        --outer-glow-angle: 0deg;
    }
    to {
        --outer-glow-angle: 360deg;
    }
}
.game-btn {
    --primary-color: #1e3a5f;
    --secondary-color: #2c5282;
    --accent-color: #4299e1;
    --glow-color: #63b3ed;
    --border-width: 2px;
    --border-radius: 12px;
    
   width: 100%;
    max-width: 200px;
    padding: 15px 30px;
    background: linear-gradient(135deg, #2c5282, #1a365d);
    border: 2px solid #4299e1;
    border-radius: 8px;
    color: white;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}
.game-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, 
        rgba(66, 153, 225, 0.4) 0%,
        rgba(66, 153, 225, 0.2) 30%,
        transparent 70%
    );
    border-radius: inherit;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: -1;
}

.game-btn:hover {
    background: linear-gradient(135deg, #3182ce, #2c5282);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(66, 153, 225, 0.4);
}

.game-btn:hover::before {
    opacity: 1;
}

.game-btn:active {
    transform: translateY(-1px) scale(0.98);
    box-shadow: 
        0 0 15px rgba(66, 153, 225, 0.8),
        0 0 30px rgba(66, 153, 225, 0.6),
        0 5px 20px rgba(0, 0, 0, 0.4);
}

/* Медиа-запросы для мобильных устройств */
@media (max-width: 768px) {
    .gameMenu {
        min-width: 90%;
        padding: 20px;
    }
    
    .game-btn {
        font-size: 16px;
        padding: 12px 25px;
    }
}

/* Добавить в CSS */
.loading-indicator {
    color: #4299e1;
    text-align: center;
    padding: 20px;
    font-size: 18px;
}

.loading-indicator i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@property --border-angle {
    syntax: "<angle>";
    initial-value: 0deg;
    inherits: false;
}

@keyframes borderRotate {
    from {
        --border-angle: 0deg;
    }
    to {
        --border-angle: 360deg;
    }
}

#mobileControls {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    display: flex;
    gap: 30px; /* Увеличено с 20px до 30px */
}

.control-btn {
    width: 80px;
    height: 80px;
    background: rgba(44, 82, 130, 0.9);
    color: white;
    border: 2px solid #4299e1;
    border-radius: 50%;
    font-size: 48px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    touch-action: manipulation;
}

.control-btn:active {
    background: rgba(66, 153, 225, 0.9);
    transform: scale(0.92);
}

@media (max-width: 768px) {
    .control-btn {
        width: 110px;
        height: 110px;
        font-size: 70px;
    }
}

@media (max-width: 480px) {
    .control-btn {
        width: 100px;
        height: 100px;
        font-size: 66px;
    }
}
#gameOverScreen {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 300;
    background: rgba(10, 20, 40, 0.95);
    padding: 40px;
    border-radius: 15px;
    border: 3px solid #2c5282;
    text-align: center;
    min-width: 300px;
}

#gameOverScreen h2 {
    color: #4299e1;
    margin-bottom: 20px;
    font-size: 28px;
}

#gameOverScreen p {
    margin: 10px 0;
    font-size: 18px;
}

#countdownOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
    pointer-events: none;
}

#countdownText {
    font-size: 120px;
    color: #4299e1;
    text-shadow: 0 0 30px rgba(66,153,225,0.7);
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}

.speed {
    background: rgba(10, 20, 40, 0.8);
    padding: 10px 15px;
    border-radius: 8px;
    border: 2px solid #2c5282;
    font-size: 16px;
    font-weight: bold;
    position: absolute;
    top: 20px;
    right: 20px;
}

.hidden {
    display: none !important;
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    #ui {
        font-size: 12px;
        top: 10px;
        left: 10px;
    }
    
    #ui > div {
        padding: 6px 10px;
        font-size: 12px;
    }
    
    .game-btn {
        padding: 12px 24px;
        font-size: 16px;
    }
    
    .control-btn {
        width: 85px;
        height: 85px;
        font-size: 20px;
    }
    
    #gameOverScreen {
        padding: 30px;
        min-width: 280px;
    }
}

@media (max-width: 480px) {
    #ui > div {
        font-size: 12px;
        padding: 6px 10px;
    }
    
    .control-btn {
        width: 80px;
        height: 80px;
        font-size: 18px;
    }
}

@keyframes cometFall {
  0% {
    transform: translate(-50%, -50%) rotate(-45deg) translateX(100vw);
    opacity: 0;
  }
  20% {
    opacity: 1;
  }
  80% {
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) rotate(-45deg) translateX(-100vw);
    opacity: 0;
  }
}

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

.comet {
  position: absolute;
  width: 100px;
  height: 1px;
  background: linear-gradient(
    90deg, 
    rgba(59,130,246,0) 0%,
    rgba(59,130,246,0.8) 30%,
    rgba(59,130,246,0.2) 70%,
    rgba(59,130,246,0) 100%
  );
  filter: drop-shadow(0 0 10px rgba(59,130,246,0.5));
  animation: cometFall 8s linear infinite;
  opacity: 0;
}
/* CSS */
#welcomeContainer {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  
}

.blinking-text {
    --neon-color: #4299e1;
    --glow-intensity: 0.5;
     z-index: 22222;
    position: relative;
    padding-bottom: 430px;
    color: var(--neon-color);
    font-size: 2.5em;
    text-align: center;
    text-shadow: 
        0 0 5px rgba(66, 153, 225, var(--glow-intensity)),
        0 0 10px rgba(66, 153, 225, var(--glow-intensity)),
        0 0 20px rgba(66, 153, 225, var(--glow-intensity)),
        0 0 40px rgba(66, 153, 225, var(--glow-intensity));
    
    animation: 
        blink 1.5s ease-in-out infinite,
        neon-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    
    /* Вендорные префиксы для совместимости */
    -webkit-animation: 
        blink 1.5s ease-in-out infinite,
        neon-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    -moz-animation: 
        blink 1.5s ease-in-out infinite,
        neon-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes blink {
    0%, 100% { opacity: 0.9; }
    50% { opacity: 0.4; }
}

@keyframes neon-pulse {
    0%, 100% {
        text-shadow: 
            0 0 5px rgba(66, 153, 225, 0.8),
            0 0 15px rgba(66, 153, 225, 0.6),
            0 0 25px rgba(66, 153, 225, 0.4),
            0 0 35px rgba(66, 153, 225, 0.2);
    }
    50% {
        text-shadow: 
            0 0 10px rgba(66, 153, 225, 1),
            0 0 20px rgba(66, 153, 225, 0.8),
            0 0 30px rgba(66, 153, 225, 0.6),
            0 0 40px rgba(66, 153, 225, 0.4);
    }
}

/* Адаптация для мобильных устройств */
@media (max-width: 768px) {
    .blinking-text {
        font-size: 1.2em;
		z-index: 22222;
        padding-bottom: 450px;
        text-shadow: 
            0 0 4px rgba(66, 153, 225, 0.6),
            0 0 8px rgba(66, 153, 225, 0.4),
            0 0 12px rgba(66, 153, 225, 0.3);
    }
}

/* Fallback для браузеров без поддержки анимаций */
@supports not (animation: blink 1s) {
    .blinking-text {
        opacity: 0.7;
        transition: opacity 0.5s ease;
    }
    .blinking-text:hover {
        opacity: 1;
    }
}

@keyframes fadeOut {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(-20px); }
}
@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}
.comet::after {
  content: '';
  position: absolute;
  right: 0;
  top: 50%;
  width: 5px;
  height: 5px;
  background: radial-gradient(
    circle, 
    rgba(255,255,255,1) 0%,
    rgba(59,130,246,1) 70%,
    rgba(59,130,246,0) 100%
  );
  transform: translateY(-50%);
  border-radius: 50%;
}

/* Генерация случайных параметров */
.comet:nth-child(1) { top: 15%; left: 10%; animation-delay: 0s; }
.comet:nth-child(2) { top: 30%; left: 30%; animation-delay: 2s; animation-duration: 10s; }
.comet:nth-child(3) { top: 45%; left: 50%; animation-delay: 4s; animation-duration: 12s; }
.comet:nth-child(4) { top: 60%; left: 70%; animation-delay: 6s; width: 200px; }
.comet:nth-child(5) { top: 75%; left: 90%; animation-delay: 8s; animation-duration: 9s; }

@media (max-width: 768px) {
  .comet {
    width: 150px;
    animation-duration: 6s !important;
  }
  .comet::after {
    width: 10px;
    height: 10px;
  }
}




.social-container {
    padding: 20px 0;

}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.social-icons a {
    color: #fff;
    font-size: 24px;
    transition: transform 0.3s ease;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(66, 153, 225, 0.2);
    border: 2px solid #4299e1;
}

.social-icons a:hover {
    transform: translateY(-3px);
    background: #4299e1;
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .social-icons {
        gap: 15px;
        flex-wrap: wrap;
    }
    
    .social-icons a {
        width: 15px;
        height: 15px;
        font-size: 20px;
    }
}

